forked from rust-lang/rust
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto merge of rust-lang#79776 - petrochenkov:mvtest, r=Mark-Simulacrum
Move some tests to subdirectories Mostly tests related to imports. (A couple of very outdated tests is also deleted.) Part of rust-lang#73494.
- Loading branch information
Showing
139 changed files
with
71 additions
and
105 deletions.
There are no files selected for viewing
File renamed without changes.
File renamed without changes.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
// run-pass | ||
mod foo { | ||
pub fn x(y: isize) { println!("{}", y); } | ||
} | ||
|
||
mod bar { | ||
use foo::x; | ||
use foo::x as z; | ||
pub fn thing() { x(10); z(10); } | ||
} | ||
|
||
pub fn main() { bar::thing(); } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,17 @@ | ||
// run-pass | ||
mod foo { | ||
pub fn x(y: isize) { println!("{}", y); } | ||
} | ||
use zed::bar; | ||
use zed::baz; //~ ERROR unresolved import `zed::baz` [E0432] | ||
//~| no `baz` in `zed` | ||
//~| HELP a similar name exists in the module | ||
//~| SUGGESTION bar | ||
|
||
|
||
mod bar { | ||
use foo::x; | ||
use foo::x as z; | ||
pub fn thing() { x(10); z(10); } | ||
mod zed { | ||
pub fn bar() { println!("bar"); } | ||
use foo; //~ ERROR unresolved import `foo` [E0432] | ||
//~^ no `foo` in the root | ||
} | ||
|
||
pub fn main() { bar::thing(); } | ||
fn main() { | ||
zed::foo(); //~ ERROR `foo` is private | ||
bar(); | ||
} |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
// run-pass | ||
|
||
use zed::bar; | ||
|
||
mod zed { | ||
pub fn bar() { println!("bar"); } | ||
} | ||
|
||
pub fn main() { bar(); } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
// run-pass | ||
|
||
use zed::bar; | ||
use baz::zed::bar; //~ ERROR unresolved import `baz::zed` [E0432] | ||
//~^ could not find `zed` in `baz` | ||
|
||
mod baz {} | ||
mod zed { | ||
pub fn bar() { println!("bar"); } | ||
pub fn bar() { println!("bar3"); } | ||
} | ||
fn main() { | ||
bar(); | ||
} | ||
|
||
pub fn main() { bar(); } |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// run-pass | ||
#![allow(unused_imports)] | ||
|
||
use baz::zed; | ||
use baz::zed::bar; | ||
|
||
mod baz { | ||
pub mod zed { | ||
pub fn bar() { println!("bar2"); } | ||
} | ||
} | ||
|
||
pub fn main() { bar(); } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,4 @@ | ||
// run-pass | ||
#![allow(unused_imports)] | ||
// error-pattern: unresolved | ||
use main::bar; | ||
|
||
use baz::zed; | ||
use baz::zed::bar; | ||
|
||
mod baz { | ||
pub mod zed { | ||
pub fn bar() { println!("bar2"); } | ||
} | ||
} | ||
|
||
pub fn main() { bar(); } | ||
fn main() { println!("foo"); } |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
// run-pass | ||
|
||
use zed::bar; | ||
|
||
mod zed { | ||
pub fn bar() { println!("bar"); } | ||
} | ||
|
||
pub fn main() { let _zed = 42; bar(); } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,7 @@ | ||
// run-pass | ||
// error-pattern: import | ||
|
||
use zed::bar; | ||
|
||
mod zed { | ||
pub fn bar() { println!("bar"); } | ||
} | ||
mod a { pub use b::foo; } | ||
mod b { pub use a::foo; } | ||
|
||
pub fn main() { let _zed = 42; bar(); } | ||
fn main() { println!("loop"); } |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.