https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70966
Bug ID: 70966 Summary: new_delete_resource() has deinit lifetime issues. Product: gcc Version: 6.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: eric at efcs dot ca Target Milestone: --- Created attachment 38422 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=38422&action=edit example.cpp The value returned from 'new_delete_resource()' should be usable at all stages of program startup and termination. In the current implementation the static deinitialization order fiasco can occur when a static object 'obj' is constructed before the first call to 'new_delete_resource()' and 'obj' references 'new_delete_resource()' in its destructor.