Add compile-fail tests for malformed glob imports
This commit is contained in:
parent
c6482c0083
commit
c4ce463f37
2
src/test/compile-fail/import-glob-path.rs
Normal file
2
src/test/compile-fail/import-glob-path.rs
Normal file
@ -0,0 +1,2 @@
|
||||
// error-pattern:cannot path into a glob
|
||||
import foo::*::bar
|
10
src/test/compile-fail/import-glob-rename.rs
Normal file
10
src/test/compile-fail/import-glob-rename.rs
Normal file
@ -0,0 +1,10 @@
|
||||
// error-pattern:globbed imports can't be renamed
|
||||
|
||||
import baz = foo::*;
|
||||
|
||||
mod foo {
|
||||
fn bar() {}
|
||||
}
|
||||
|
||||
fn main() {
|
||||
}
|
Loading…
Reference in New Issue
Block a user