about summary refs log tree commit diff
path: root/tests/ui/cfg/cfg_false_no_std-2.rs
blob: 666c90deaf0f4a86eb47d373bd62c8d205358ae6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// Error, the linked empty library is `no_std` and doesn't provide a panic handler.

//@ dont-check-compiler-stderr

// NOTE: fix a panic strategy to prevent differing errors subject to target's default panic strategy
// which changes between targets. The specific panic strategy doesn't matter for test intention.
//@ compile-flags: -Cpanic=abort

//@ aux-build: cfg_false_lib_no_std_before.rs

#![no_std]

extern crate cfg_false_lib_no_std_before as _;

fn main() {}

//~? ERROR `#[panic_handler]` function required, but not found