Macro claim::assert_ge [−][src]
Asserts that first expression is greater or equal than the second.
Requires that both expressions be comparable with >=
.
Uses
Assertions are always checked in both debug and release builds, and cannot be disabled.
See debug_assert_ge
for assertions that are not enabled in release builds by default.
Custom messages
This macro has a second form, where a custom panic message can be provided
with or without arguments for formatting. See std::fmt
for syntax for this form.
Examples
assert_ge!(2, 1); // With custom messages assert_ge!(2, 1, "Expecting that {} is greater or equal than {}", 2, 1); assert_ge!(5, 5, "Expecting that both arguments are equal");
ⓘ
assert_ge!(5, 6); // Will panic