@@ -190,7 +190,6 @@ impl<'a> Location<'a> {
190190 /// # Examples
191191 ///
192192 /// ```
193- /// #![feature(track_caller)]
194193 /// use core::panic::Location;
195194 ///
196195 /// /// Returns the [`Location`] at which it is called.
@@ -206,7 +205,7 @@ impl<'a> Location<'a> {
206205 ///
207206 /// let fixed_location = get_just_one_location();
208207 /// assert_eq!(fixed_location.file(), file!());
209- /// assert_eq!(fixed_location.line(), 15 );
208+ /// assert_eq!(fixed_location.line(), 14 );
210209 /// assert_eq!(fixed_location.column(), 5);
211210 ///
212211 /// // running the same untracked function in a different location gives us the same result
@@ -217,7 +216,7 @@ impl<'a> Location<'a> {
217216 ///
218217 /// let this_location = get_caller_location();
219218 /// assert_eq!(this_location.file(), file!());
220- /// assert_eq!(this_location.line(), 29 );
219+ /// assert_eq!(this_location.line(), 28 );
221220 /// assert_eq!(this_location.column(), 21);
222221 ///
223222 /// // running the tracked function in a different location produces a different value
@@ -226,13 +225,8 @@ impl<'a> Location<'a> {
226225 /// assert_ne!(this_location.line(), another_location.line());
227226 /// assert_ne!(this_location.column(), another_location.column());
228227 /// ```
229- // FIXME: When stabilizing this method, please also update the documentation
230- // of `intrinsics::caller_location`.
231- #[ unstable(
232- feature = "track_caller" ,
233- reason = "uses #[track_caller] which is not yet stable" ,
234- issue = "47809"
235- ) ]
228+ #[ stable( feature = "track_caller" , since = "1.46.0" ) ]
229+ #[ rustc_const_unstable( feature = "const_caller_location" , issue = "47809" ) ]
236230 #[ track_caller]
237231 pub const fn caller ( ) -> & ' static Location < ' static > {
238232 crate :: intrinsics:: caller_location ( )
0 commit comments