C++ Bug compiling the 'virtual' keyword

Nathan Sidwell nathan@codesourcery.com
Tue Jun 6 01:29:00 GMT 2000


Adam Pierce wrote:
> 
> Thanks for the excellent compiler. I use gcc frequently on Linux and find it very useful.
> 
> I've just installed gcc-2.95.2 on my Sparc/Solaris 7 box and have noticed an odd problem. Consider this very simple header file..
>
> 
> If I put this in /usr/local/include, my source files (located elsewhere) can include it and it compiles perfectly. However, if I move the header file to /usr/include, or any subdirectory under /usr/include, I get this:

Most likely some #define is doing something wierd. Look at the preprocessed
output (obtained with -E), also you might need to use the -dD option, which
leaves the #define definitions in as well. That'll help you track down
whats being included from where. Also the -v option will tell you the
compiler's #include search order.

nathan

-- 
Dr Nathan Sidwell   ::   http://www.codesourcery.com   ::   CodeSourcery LLC
         'But that's a lie.' - 'Yes it is. What's your point?'
nathan@codesourcery.com : http://www.cs.bris.ac.uk/~nathan/ : nathan@acm.org


More information about the Gcc-bugs mailing list