File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -123,8 +123,9 @@ impl<'a> Location<'a> {
123
123
/// ```
124
124
#[ must_use]
125
125
#[ stable( feature = "panic_hooks" , since = "1.10.0" ) ]
126
+ #[ rustc_const_unstable( feature = "const_caller_location" , issue = "76156" ) ]
126
127
#[ inline]
127
- pub fn file ( & self ) -> & str {
128
+ pub const fn file ( & self ) -> & str {
128
129
self . file
129
130
}
130
131
@@ -147,8 +148,9 @@ impl<'a> Location<'a> {
147
148
/// ```
148
149
#[ must_use]
149
150
#[ stable( feature = "panic_hooks" , since = "1.10.0" ) ]
151
+ #[ rustc_const_unstable( feature = "const_caller_location" , issue = "76156" ) ]
150
152
#[ inline]
151
- pub fn line ( & self ) -> u32 {
153
+ pub const fn line ( & self ) -> u32 {
152
154
self . line
153
155
}
154
156
@@ -171,8 +173,9 @@ impl<'a> Location<'a> {
171
173
/// ```
172
174
#[ must_use]
173
175
#[ stable( feature = "panic_col" , since = "1.25.0" ) ]
176
+ #[ rustc_const_unstable( feature = "const_caller_location" , issue = "76156" ) ]
174
177
#[ inline]
175
- pub fn column ( & self ) -> u32 {
178
+ pub const fn column ( & self ) -> u32 {
176
179
self . col
177
180
}
178
181
}
You can’t perform that action at this time.
0 commit comments