mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-01 14:21:44 +00:00
fix: Allow flyimport to import primitive shadowing modules
This commit is contained in:
parent
062822ce91
commit
0851d21d1e
4 changed files with 28 additions and 2 deletions
|
@ -1618,3 +1618,18 @@ pub struct FooStruct;
|
|||
"#]],
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn primitive_mod() {
|
||||
check(
|
||||
r#"
|
||||
//- minicore: str
|
||||
fn main() {
|
||||
str::from$0
|
||||
}
|
||||
"#,
|
||||
expect![[r#"
|
||||
fn from_utf8_unchecked(…) (use core::str) const unsafe fn(&[u8]) -> &str
|
||||
"#]],
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue