-
Notifications
You must be signed in to change notification settings - Fork 13.4k
Naming of proc_macro::Span::local_file() #139903
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Comments
FWIW, rustc internally uses "LocalPath" for this: rust/compiler/rustc_span/src/lib.rs Line 196 in 9857284
|
I personally think |
@rust-lang/libs-api If you have an opinion/ideas, please speak up! |
I weakly prefer |
We discussed this last week in the libs-api meeting. We didn't have any better ideas than I'll make a PR to stabilize it under that name and propose an FCP. |
Stabilize proc_macro::Span::{file, local_file}. Stabilizes this part of rust-lang#54725: ```rust impl Span { pub fn file(&self) -> String; // Mapped/artificial file name, for display purposes. pub fn local_file(&self) -> Option<PathBuf>; // Real file name as it exists on the local file system. } ``` See also the naming discussion in rust-lang#139903
Stabilize proc_macro::Span::{file, local_file}. Stabilizes this part of rust-lang#54725: ```rust impl Span { pub fn file(&self) -> String; // Mapped/artificial file name, for display purposes. pub fn local_file(&self) -> Option<PathBuf>; // Real file name as it exists on the local file system. } ``` See also the naming discussion in rust-lang#139903
Stabilize proc_macro::Span::{file, local_file}. Stabilizes this part of rust-lang/rust#54725: ```rust impl Span { pub fn file(&self) -> String; // Mapped/artificial file name, for display purposes. pub fn local_file(&self) -> Option<PathBuf>; // Real file name as it exists on the local file system. } ``` See also the naming discussion in rust-lang/rust#139903
Stabilize proc_macro::Span::{file, local_file}. Stabilizes this part of rust-lang/rust#54725: ```rust impl Span { pub fn file(&self) -> String; // Mapped/artificial file name, for display purposes. pub fn local_file(&self) -> Option<PathBuf>; // Real file name as it exists on the local file system. } ``` See also the naming discussion in rust-lang/rust#139903
Stabilize proc_macro::Span::{file, local_file}. Stabilizes this part of rust-lang#54725: ```rust impl Span { pub fn file(&self) -> String; // Mapped/artificial file name, for display purposes. pub fn local_file(&self) -> Option<PathBuf>; // Real file name as it exists on the local file system. } ``` See also the naming discussion in rust-lang#139903
Stabilize proc_macro::Span::{file, local_file}. Stabilizes this part of rust-lang/rust#54725: ```rust impl Span { pub fn file(&self) -> String; // Mapped/artificial file name, for display purposes. pub fn local_file(&self) -> Option<PathBuf>; // Real file name as it exists on the local file system. } ``` See also the naming discussion in rust-lang/rust#139903
Uh oh!
There was an error while loading. Please reload this page.
This is about #54725's open question on the name of
local_file
:The unstable API is now:
The question is: What should we name
local_file
?Keeping it as
local_file
is an option, but maybe we can think of something better.The text was updated successfully, but these errors were encountered: