In a tangential aside to a now-closed GitHub ticket, John wrote: > std::auto_ptr has actually been deprecated in C++11 > > http://en.wikipedia.org/wiki/Auto_ptr > > So for that one I'd say let's just wait a few more years and replace > AutoPtr with std::unique_ptr instead...
>From what I'm reading about C++11, std::unique_ptr could basically be described as "auto_ptr, but using rvalue references to turn run-time errors into compile-time errors". So we could probably typedef unique_ptr as AutoPtr just as soon as we add a --enable-cxx11 option to configure. Although I still don't want to require C++11 any time soon, it might be nice to have as an option, with some macros to enable selective backwards-compatible enabling of a few features. It appears that constexpr, move constructors, and rvalue-moving operator overloads, if used properly, can be easily omitted (or in the constexpr case replaced with const) to get equivalent C++03 code that's merely less well optimized. Static asserts can be omitted to get equivalent C++03 code that's merely less well tested. And method override identifiers can be omitted to get legal C++03 code that's merely less of either. There doesn't seem to be any way to allow for lambdas, auto, range loops, or other niceities without breaking C++03 compatibility, which I'd rather not do for any existing libMesh subsystems.` --- Roy ------------------------------------------------------------------------------ Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS, MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft MVPs and experts. ON SALE this month only -- learn more at: http://p.sf.net/sfu/learnmore_123012 _______________________________________________ Libmesh-devel mailing list Libmesh-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libmesh-devel