Script.static_assert¶
- static Script.static_assert(cond, msg)¶
Assert a compile-time condition.
Raises
AssertionErrorat compile time if the condition is false. The condition must be a compile-time constant (aboolor aConstantexpression).- Parameters:
cond (bool | Expr) – The compile-time condition to check. Must be a constant value.
msg (str) – The error message to display if the assertion fails.
- Return type:
None