assert does not run side effects

In Godot, assert statements and the code inside of them do not get executed in debug builds. This means that any expression provided as the condition for the assert statement will not run in release builds. If this conditional expression contains a side-effect, then the release build will behave differently from the debug build. 1

Footnotes

  1. 20250503182450