debug_validate

Function debug_validate 

Source
pub fn debug_validate<P: ValidationPolicy>(value: &P::Value, msg: &str)
Expand description

Validates a value using the given policy, but only in debug builds. In release builds, this function is a no-op and should be optimized away.

ยงPanics

In debug builds, this function will panic if P::validate_ref(value) returns an Err.