egcs 1.1b: no global ctor called if main in namespace
Alexandre Oliva
oliva@dcc.unicamp.br
Mon Oct 26 18:00:00 GMT 1998
Yves Bastide <stid@lminux.univ-bpclermont.fr> writes:
> On a powerpc-ibm-aix4.1.5.0, putting the main() function
> into a namespace (other than the specially handled std)
> prevents the constructors of global variables from being
> called.
main() is not reserved in namespaces other than the global namespace.
Because of a bug, its name was mangled as if it were the special
::main() function, but this is fixed in the current sources. Your
program shouldn't link because ::main() is not defined.
--
Alexandre Oliva
mailto:oliva@dcc.unicamp.br mailto:oliva@gnu.org mailto:aoliva@acm.org
http://www.dcc.unicamp.br/~oliva
Universidade Estadual de Campinas, SP, Brasil
More information about the Gcc-bugs
mailing list