points
The correct way to solve this is with debug asserts (as in Rust, or how the parent described).