File tree Expand file tree Collapse file tree 3 files changed +15
-8
lines changed Top Open diff view settings Expand file tree Collapse file tree 3 files changed +15
-8
lines changed Top Open diff view settings Original file line number Diff line number Diff line change @@ -240,7 +240,6 @@ run-make/unknown-mod-stdin/Makefile
240240run-make/unstable-flag-required/Makefile
241241run-make/use-suggestions-rust-2018/Makefile
242242run-make/used-cdylib-macos/Makefile
243- run-make/used/Makefile
244243run-make/volatile-intrinsics/Makefile
245244run-make/wasm-exceptions-nostd/Makefile
246245run-make/wasm-override-linker/Makefile
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ // This test ensures that the compiler is keeping static variables, even if not referenced
2+ // by another part of the program, in the output object file.
3+ //
4+ // It comes from #39987 which implements this RFC for the #[used] attribute:
5+ // https://rust-lang.github.io/rfcs/2386-used.html
6+
7+ //@ ignore-msvc
8+
9+ use run_make_support:: { cmd, rustc} ;
10+
11+ fn main ( ) {
12+ rustc ( ) . opt_level ( "3" ) . emit ( "obj" ) . input ( "used.rs" ) . run ( ) ;
13+
14+ cmd ( "nm" ) . arg ( "used.o" ) . run ( ) . assert_stdout_contains ( "FOO" ) ;
15+ }
You can’t perform that action at this time.
0 commit comments