Re: [Patch] Warning fixes
- From: Hans Breuer <hans breuer org>
- To: Owen Taylor <otaylor redhat com>
- Cc: Tor Lillqvist <tml iki fi>, degger fhm edu, gtk-devel-list gnome org
- Subject: Re: [Patch] Warning fixes
- Date: Thu, 15 Nov 2001 23:06:35 +0100
At 19:31 14.11.01 -0500, Owen Taylor wrote:
>
>> Owen Taylor writes:
>> > This is wrong. GDKVAR is needed on Win32 .. the right thing here is
>> > to define GDKVAR differently in this case... Tim did a fix like
>> > this for some stuff in GTK+ recently.
>>
>> [...]
>
>Don't we need extern for header files when compiling GDK as
>well?
I think so.
>Perhaps we need different GDKVAR names for header
>files and C files?
>
AFAIK GTKVAR could simply be restricted to being the replacement
for 'extern' (only used in the header/declaration). At least with
msvc it isn't necessary to duplicate the __declspec (dllexport)
modifier for the actual 'instantiation' (in the .c file).
I would go so far to claim that the linker should report
an unresolved symbol error if all declarations of a variable
in a dll are prefixed with extern (= instance from elsewhere).
But msvc automatically creates an instance than.
Mingw/gcc may require a different solution ...
Hans
-------- Hans "at" Breuer "dot" Org -----------
Tell me what you need, and I'll tell you how to
get along without it. -- Dilbert
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]