You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given the following src/main.rs, the rust-analyzer(unresolved-module) and code actions correctly suggest creating “const.rs” or “const/mod.rs”.
mod r#const;fnmain(){}
But given the following src/const.rs, they suggest creating “r#const/foo.rs” or “r#const/foo/mod.rs”, even when src/const/foo.rs or src/const/foo/mod.rs exists.
mod foo;
If we rename src/const/foo.rs to src/r#const/foo.rs as suggested, the rust-analyzer(unresolved-module) goes away, but we now have a rustc(E0583) essentially telling us to rename it back, so it looks like including “r#” in module filenames is incorrect.
The text was updated successfully, but these errors were encountered:
rust-analyzer version: 0.3.1186-standalone (e8e598f 2022-08-28)
rustc version: 1.65.0-nightly (ce36e8825 2022-08-28)
Create a project with cargo new --bin foo.
Given the following src/main.rs, the rust-analyzer(unresolved-module) and code actions correctly suggest creating “const.rs” or “const/mod.rs”.
But given the following src/const.rs, they suggest creating “r#const/foo.rs” or “r#const/foo/mod.rs”, even when src/const/foo.rs or src/const/foo/mod.rs exists.
If we rename src/const/foo.rs to src/r#const/foo.rs as suggested, the rust-analyzer(unresolved-module) goes away, but we now have a rustc(E0583) essentially telling us to rename it back, so it looks like including “r#” in module filenames is incorrect.
The text was updated successfully, but these errors were encountered: