3 ms·
Defer is used to automatically release resources on function exit, I'm not sure how result types will help here. Can you give an example?
by kgeist 5y ago
Defer is used to automatically release resources on function exit, I'm not sure how result types will help here. Can you give an example?
- the_gipsy 5y agoIt's an alternative to try...finally or RAII.