This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libstdc++/39796] cin/cout/cerr constructors should run at high priority when possible


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39796

Jonathan Wakely <redi at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2012-01-03
     Ever Confirmed|0                           |1

--- Comment #4 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-01-03 16:39:39 UTC ---
http://stackoverflow.com/questions/8708539/order-of-initialization was brought
to my attention, which crashes without messing with init-priority

struct Foo
{

   Foo();
}foo;

#include <iostream>

Foo::Foo()
{
   std::cout << "Hello World";
}

int main() {}

So I'm confirming this as a valid enhancement.

PR 44952 might lead to a better way to ensure the initialization is done once
as early as possible.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]