This is the mail archive of the gcc@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]
Other format: [Raw text]

compiles under g++ but not gcc


Hello, not sure I'm posting this to the right list, but I couldn't seem
to find any others.

I've noticed a problem compiling under g++ and gcc. a program I am
working on compiles fine under g++, but gives a number of errors with
gcc.
I have defined a simple structure in a header file, included this header
in the main file that uses this structure, and when I compile under gcc,
I get errors related to all variables of that structure type (the one
defined in the header); it does not recognize the structure type that
was defined in the header. When compiling under g++, there is no problem
at all.

While I could use try to use g++ to make this problem go away, I'd like
to know first why it's happening, and how to use gcc, as there's a
possibility I won't have access to g++ at the school's lab.

thanks!



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