Macro ffi_support::static_assert [−][src]
Force a compile error if the condition is not met. Requires a unique name for the assertion for… reasons. This is included mainly because it’s a common desire for FFI code, but not for other sorts of code.
Examples
Failing example:
ⓘ
ffi_support::static_assert!(THIS_SHOULD_FAIL, false);
Passing example:
ffi_support::static_assert!(THIS_SHOULD_PASS, true);