This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: C++ Bug compiling the 'virtual' keyword


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

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]