2 ms·
Eh? RAII works perfectly fine without exceptions. Either - You write a constructor that cannot fail for RAII types that cannot fail, or - return some kind of op
by nshepperd 10y ago
Eh? RAII works perfectly fine without exceptions. Either
- You write a constructor that cannot fail for RAII types that cannot fail, or
- return some kind of option type from your BuildRAII() function, and handle the failure case however you want.