Skip to content

Commit cccc94a

Browse files
bjacotgcopybara-github
authored andcommitted
Add #[track_caller] since near can panic.
PiperOrigin-RevId: 655891873
1 parent 896b468 commit cccc94a

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

googletest/src/matchers/near_matcher.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ use std::fmt::Debug;
110110
/// # }
111111
/// # should_pass().unwrap();
112112
/// ```
113+
#[track_caller]
113114
pub fn near<T: Debug + Float + Copy>(expected: T, max_abs_error: T) -> NearMatcher<T> {
114115
if max_abs_error.is_nan() {
115116
panic!("max_abs_error must not be NaN");

0 commit comments

Comments
 (0)