mirror of https://github.com/zkat/miette.git
Fix unused code warnings in tests (using black_box)
Signed-off-by: Justus Flügel <justusfluegel@gmail.com>
This commit is contained in:
parent
ff32d81cb0
commit
bc7b842ca3
|
|
@ -159,6 +159,9 @@ fn transparent_generic() {
|
||||||
Custom,
|
Custom,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::hint::black_box(Combined::<i32>::Other(1));
|
||||||
|
std::hint::black_box(Combined::<i32>::Custom);
|
||||||
|
|
||||||
assert_impl_diagnostic::<Combined<miette::MietteDiagnostic>>();
|
assert_impl_diagnostic::<Combined<miette::MietteDiagnostic>>();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -260,6 +263,9 @@ fn generic_diagnostic_source() {
|
||||||
Custom,
|
Custom,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::hint::black_box(Combined::<i32>::Other(1));
|
||||||
|
std::hint::black_box(Combined::<i32>::Custom);
|
||||||
|
|
||||||
assert_impl_diagnostic::<Combined<miette::MietteDiagnostic>>();
|
assert_impl_diagnostic::<Combined<miette::MietteDiagnostic>>();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -273,5 +279,8 @@ fn generic_not_influencing_default() {
|
||||||
Custom,
|
Custom,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::hint::black_box(Combined::<i32>::Other(1));
|
||||||
|
std::hint::black_box(Combined::<i32>::Custom);
|
||||||
|
|
||||||
assert_impl_diagnostic::<Combined<i32>>();
|
assert_impl_diagnostic::<Combined<i32>>();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue