Re: glib\guitls.h, atexit and the windows DDK
- From: Tor Lillqvist <tml iki fi>
- To: Rick Jones <rick jones2 hp com>
- Cc: gtk-list gnome org
- Subject: Re: glib\guitls.h, atexit and the windows DDK
- Date: Thu, 9 Mar 2006 01:12:49 +0200
Rick Jones writes:
> int __cdecl atexit(void (__cdecl *)(void));
> did indeed make the error go away when compiling under the DDK.
What compiler is used in that case, BTW, as I get no errors or
warnings when compiling a program that includes both stdlib.h (where
the official declaration of atexit() is) and gutils.h (without any
__cdecl) either with MSVC6 or MSVC8?
I hope you aren't using some compiler switch that makes something else
than __cdecl the default calling convention for functions without
explicitly specified calling convention? Or do the DDK headers do
this, but don't pop the default back? The GLib (and GTK+, etc) headers
don't specify any calling convention, and things will go horribly
wrong if you compile code that calls GLib, GTK+ etc functions with the
wrong calling convention. We haven't wanted to uglify the GLib, GTK+,
etc headers by adding explicit calling convention decorations for
Win32's sake, and nobody has complained so far.
--tml
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]