rust
rust copied to clipboard
Tracking Issue for `const_location_fields`
Feature gate: #![feature(const_location_fields)]
This is a tracking issue for core::panic::Location
methods as const
functions.
Public API
// core::panic::location
impl Location {
pub const fn file(&self) -> &str;
pub const fn line(&self) -> u32;
pub const fn column(&self) -> u32;
}
Steps / History
- [x] Implementation: #101030
- [ ] Final comment period (FCP)
- [ ] Stabilization PR
Unresolved Questions
- None yet.
anything needed before both this and #76156 can be stabilized?
@programmerjake I think there is no blocker for stabilization since the functions just return a field value. However, I'm not sure if Location::caller can be stabilized. Additional testing is probably needed regarding its use in const generic parameters, macros, and so on.
@programmerjake @lilasta doesn't seem to be any blockers here and this has sat long enough so all what's missing is someone sending the pr to stabilise it, so feel free to do so if you are interested
FCP started in #76156 which also covers this issue.