2 ms·
> "Accidentally" asking the language to do something time-expensive is as impossible in C as forgetting a free() in Haskell. Unless you use GCC's cleanup exten
by cesarb 9y ago
> "Accidentally" asking the language to do something time-expensive is as impossible in C as forgetting a free() in Haskell.
Unless you use GCC's cleanup extension (which runs an arbitrary function when leaving a scope, similar to Rust's Drop trait). Or evil macros which turn innocent-looking code into something else (a well-known project, in some compilation modes, redefines the "if" keyword to track how many times each branch is taken). Or both at the same time (like hiding GCC's cleanup extension with a macro).