Is assert evil? [closed]
No, there’s nothing wrong with assert as long as you use it as intended. That is, it’s supposed to be for catching cases that “can’t happen”, during debugging, as opposed to normal error handling. Assert: A failure in the program’s logic itself. Error Handling: An erroneous input or system state not due to a bug … Read more