Nameless struct problem

Patrik Stridvall ps at
Mon Nov 18 04:03:37 CST 2002

> Dimitrie O. Paun wrote:
> >I had to use the following hack to allow this
> >bit to go through my g++ compiler.
> >
> >I'm using RedHat 8.0, so this gives me:
> >
> >[dimi at dimi wine.src]$ g++ --version
> >g++ (GCC) 3.2 20020903 (Red Hat Linux 8.0 3.2-7)
> >Copyright (C) 2002 Free Software Foundation, Inc.
> >This is free software; see the source for copying 
> conditions.  There is NO
> >warranty; not even for MERCHANTABILITY or FITNESS FOR A 
> >
> Glad you included the warranty bit :-)
> >
> >Any ideas what's wrong here, and how it can be fixed?
> >  
> >
> Not particularly, but I know I've seen other examples of g++ 
> being more 
> strict / particular
> about structs than gcc. What error do you get? You could try 
> -E for the 
> preprocessor
> output and search through it for DUMMYSTRUCTNAME ; it could 
> be being defined
> earlier on or somewhere else in a way that confuses it here...

DUMMYSTRUCT is defined as nothing if the compiler supports
nameless structs. GNU C++ was mistakenly believed by me to support
nameless structs. I didn't check however, I have check now
and it seem like no version of GNU C++ does. :-(

Not that it really needs to support it since you could get the same
effect with "dummy" structs/classes and inheritence, but then I
really can't see any particular reason not to support it since
makes at least as much sense (if not more) in C++ to have unnamed
structs as in C...

Anyway, there is a patch in wine-patches that fixes the problem and
since it as I said is always possible to "fake it" in C++ there
is no great need to ask the GNU C++ developers the fix the problem

More information about the wine-devel mailing list