> local try/catch-es are examples of exception misuses.
Not in the context of RAII. It helps a lot with cleanup and ensuring nothing leaks from the snippet that caused the exception if any resources were acquired.
Whereas in C you'd have to make all that cleanup manually, which can be tedious and error prone.
Not in the context of RAII. It helps a lot with cleanup and ensuring nothing leaks from the snippet that caused the exception if any resources were acquired.
Whereas in C you'd have to make all that cleanup manually, which can be tedious and error prone.