mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-02 22:54:58 +00:00
Fix tests that depended on loose visibility restriction
This commit is contained in:
parent
e75afebeb2
commit
19306c070d
12 changed files with 90 additions and 89 deletions
|
@ -268,12 +268,12 @@ fn main() {
|
|||
foo::Foo { bar: 3, $0baz: false};
|
||||
}
|
||||
//- /foo.rs
|
||||
struct Foo {
|
||||
pub struct Foo {
|
||||
bar: i32
|
||||
}
|
||||
"#,
|
||||
r#"
|
||||
struct Foo {
|
||||
pub struct Foo {
|
||||
bar: i32,
|
||||
pub(crate) baz: bool
|
||||
}
|
||||
|
|
|
@ -71,9 +71,9 @@ use a;
|
|||
use a::{c, d::e};
|
||||
|
||||
mod a {
|
||||
mod c {}
|
||||
mod d {
|
||||
mod e {}
|
||||
pub mod c {}
|
||||
pub mod d {
|
||||
pub mod e {}
|
||||
}
|
||||
}
|
||||
"#,
|
||||
|
@ -87,9 +87,9 @@ use a::{
|
|||
};
|
||||
|
||||
mod a {
|
||||
mod c {}
|
||||
mod d {
|
||||
mod e {}
|
||||
pub mod c {}
|
||||
pub mod d {
|
||||
pub mod e {}
|
||||
}
|
||||
}
|
||||
"#,
|
||||
|
@ -116,11 +116,11 @@ use b;
|
|||
);
|
||||
check_fix(
|
||||
r#"
|
||||
mod a { mod c {} }
|
||||
mod a { pub mod c {} }
|
||||
use a::{c$0};
|
||||
"#,
|
||||
r#"
|
||||
mod a { mod c {} }
|
||||
mod a { pub mod c {} }
|
||||
use a::c;
|
||||
"#,
|
||||
);
|
||||
|
@ -136,11 +136,11 @@ use a;
|
|||
);
|
||||
check_fix(
|
||||
r#"
|
||||
mod a { mod c {} mod d { mod e {} } }
|
||||
mod a { pub mod c {} pub mod d { pub mod e {} } }
|
||||
use a::{c, d::{e$0}};
|
||||
"#,
|
||||
r#"
|
||||
mod a { mod c {} mod d { mod e {} } }
|
||||
mod a { pub mod c {} pub mod d { pub mod e {} } }
|
||||
use a::{c, d::e};
|
||||
"#,
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue