Improving C++: Adding defer from Go

The problem

C-style solution: Goto

C++ style solution: Managed Objects

Go-style solution: Defer

C++ defer implementation

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Daniel Trugman

Daniel Trugman

A software specialist passionate about elegant and efficient technology. I Love learning and sharing my knowledge.