Commit 9f5af26d by Martin Sebor Committed by Martin Sebor

PR c++/52477 - Wrong initialization order __attribute__((constructor)) vs static data access

* doc/extend.texi (attribute constructor): Document present limitation.

From-SVN: r246288
parent b0ba96c2
2017-03-20 Martin Sebor <msebor@redhat.com>
PR c++/52477
* doc/extend.texi (attribute constructor): Document present limitation.
2017-03-20 Kelvin Nilsen <kelvin@gcc.gnu.org>
PR target/79963
......
......@@ -2510,7 +2510,11 @@ if you have a constructor that allocates a resource and a destructor
that deallocates the same resource, both functions typically have the
same priority. The priorities for constructor and destructor
functions are the same as those specified for namespace-scope C++
objects (@pxref{C++ Attributes}).
objects (@pxref{C++ Attributes}). However, at present, the order in which
constructors for C++ objects with static storage duration and functions
decorated with attribute @code{constructor} are invoked is unspecified.
In mixed declarations, attribute @code{init_priority} can be used to
impose a specific ordering.
@item deprecated
@itemx deprecated (@var{msg})
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment