DataTex icon indicating copy to clipboard operation
DataTex copied to clipboard

Improve exception safety with smart pointers

Open elfring opened this issue 2 years ago • 4 comments

Would you like to wrap any pointers with the class template “std::unique_ptr”?

Update candidates:

elfring avatar Mar 07 '23 20:03 elfring

I find unique and shared pointers very interesting. But first I need to test them because I ve never used them before. What is your idea of using them?

CSMathematics avatar Mar 08 '23 14:03 CSMathematics

:thought_balloon: Would you like to take the C++ guideline “R.11: Avoid calling new and delete explicitly” better into account?

elfring avatar Mar 08 '23 14:03 elfring

I see that is really helpful and promissing. I think I'm going to be using smart pointers from now on more often.

CSMathematics avatar Mar 08 '23 16:03 CSMathematics

By the way: :thought_balloon: The management of parent-child relationships needs further development attention (as usual).

elfring avatar Mar 09 '23 15:03 elfring