[SDL] sdl program compiled with "-O2 -g0" takes ages to start
Mason Wheeler
masonwheeler at yahoo.com
Mon Jun 29 11:13:24 PDT 2009
>From: Bob Pendleton <bob at pendleton.com>
>Subject: Re: [SDL] sdl program compiled with "-O2 -g0" takes ages to start
>On Mon, Jun 29, 2009 at 12:07 AM, Vassilis
>Virvilis<vasvir at iit.demokritos.gr> wrote:
>>
>> Looks like the infamous "static initialization order fiasco"
>>
>> http://www.parashift.com/c++-faq-lite/ctors.html#faq-10.12
>
>Exactly. Static initialization in C++ is a very powerful tool, rather
>like a hand grenade. Used mindfully, by a trained practitioner, it is
>an extremely effective way of solving problems. Used by an amateur it
>gives you a dead amateur and maybe some dead and injured bystanders
>too. May be not the best example I ever came up with... :-)
"Powerful" isn't the word I'd use to describe a feature that leaves one of
its most important pieces of functionality undefined, and makes it all too
easy to write code that depends on this undefined functionality. I believe
"defective" would be a more accurate term.
http://yosefk.com/c++fqa/ctors.html#fqa-10.12
More information about the SDL
mailing list