3 files changed +20
-12
lines changed Original file line number Diff line number Diff line change @@ -6,7 +6,6 @@ run-make/c-static-rlib/Makefile
6
6
run-make/c-unwind-abi-catch-lib-panic/Makefile
7
7
run-make/cat-and-grep-sanity-check/Makefile
8
8
run-make/cdylib-dylib-linkage/Makefile
9
- run-make/compiler-lookup-paths-2/Makefile
10
9
run-make/compiler-rt-works-on-mingw/Makefile
11
10
run-make/crate-hash-rustc-version/Makefile
12
11
run-make/cross-lang-lto-clang/Makefile
Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ // This test checks that extern crate declarations in Cargo without a corresponding declaration
2
+ // in the manifest of a dependency are NOT allowed. The last rustc call does it anyways, which
3
+ // should result in a compilation failure.
4
+ // See https://github.com/rust-lang/rust/pull/21113
5
+
6
+ use run_make_support:: { path, rfs, rust_lib_name, rustc} ;
7
+
8
+ fn main ( ) {
9
+ rfs:: create_dir ( "a" ) ;
10
+ rfs:: create_dir ( "b" ) ;
11
+ rustc ( ) . input ( "a.rs" ) . run ( ) ;
12
+ rfs:: rename ( rust_lib_name ( "a" ) , path ( "a" ) . join ( rust_lib_name ( "a" ) ) ) ;
13
+ rustc ( ) . input ( "b.rs" ) . library_search_path ( "a" ) . run ( ) ;
14
+ rfs:: rename ( rust_lib_name ( "b" ) , path ( "b" ) . join ( rust_lib_name ( "b" ) ) ) ;
15
+ rustc ( )
16
+ . input ( "c.rs" )
17
+ . library_search_path ( "crate=b" )
18
+ . library_search_path ( "dependency=a" )
19
+ . run_fail ( ) ;
20
+ }
0 commit comments