This is the mail archive of the
mailing list for the Cygwin project.
RE: GCC4 status.
- From: Danny Smith <dannysmith at clear dot net dot nz>
- To: cygwin-apps at cygwin dot com
- Date: Thu, 26 Feb 2009 18:05:08 +1300
- Subject: RE: GCC4 status.
Dave Korn wrote:
> Corinna Vinschen wrote:
> > So why does it do that at all: "previous dllimport ignored"?
> > It shouldn't do that. The dllimport should have precedence, IMHO.
> I don't know why it does that, it's just the behaviour of
> vanilla upstream
> GCC. I think it might be important, and have a vague memory
> of some PR
> relating to this in the bugzilla. I'll take a closer look.
It does that because native MS compiler does that as do/did other Windows compilers (I
think MSVC actually says "dllexport assumed"). The behaviour is due to a patch committed
in gcc 3.0 development but was also in the sources used by cygwin and mingw in 2.95.3
days. There are several testsuite cases that expect this behaviour.
In olden (pre -funit-at-a-time) days it was critical because without the override
semantics we would sometimes get a function being used as a dllimport than later in the
same TU it would find a definition and the RTL generation would blow up.