Function std::flags::panic_on_overflow_enabled
pub fn panic_on_overflow_enabled() -> bool Expand description
Checks if the panic-on-overflow flag is set in the FuelVM.
Returns
- [bool] -
trueifpanic-on-overflowis enabled.falseotherwise.
Examples
use std::flags::panic_on_overflow_enabled;
fn main() {
let is_enabled = panic_on_overflow_enabled();
// Panic on overflow is enabled by default.
assert(is_enabled);
}