Re: isalnum not declared CODE

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Nicolai,

Your example (with some tweaking) worked on my platform.

My platform is Cygwin / WinXPpro (NT 5.1sp1a) and GCC 3.3.1 (cygming special).

The tweaking should be immaterial. Things like putting in function bodies for String, changing #include <iostream.h> to #include <iostream>, adding in "std::" prefixes in the few spots they're needed, changing where top points to in the makefile.

Keep in mind that ctype.h is not part of GCC; it's supplied by your distribution (Slackware).

It appears that either your GCC was built for a different version of Slackware,
or... you have a filename collision (perhaps due to case insensitive filesystem?)
or... you could try putting #include <cctype> in your main.cc


Generally speaking, it's bad practice to name your project's header files the same as the system header files. Even if they differ in case, such as <ctype.h> versus "CType.h".

Try this:
g++ -E -dI -c main.cc

That should show you if you are actually including the Slackware /usr/include/ctype.h as you expect. I suspect you are not getting what you think you should be getting.

Sincerely,
--Eljay


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux