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]

(gcc 2.95 NT4 SP6) function declaration with enum argument


When I try to compile the following code using gcc 2.95 on NT4 SP6:

#include <string>
enum TLanguage;
std::string GetLanguageString(TLanguage);

I get:

use of enum `TLanguage' without previous declaration

I think that my code is correct; an incomplete type is sufficient for the
arguments/return type of a function declaration.

Thomas


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