Error: string is not a member of std - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Error: string is not a member of std

kchakuskchakus Posts: 8Member
Hi,
I'm trying to compile a C++ program on Solaris 2.10 with SUN CC5.5 latest patch level.
I'm facing an issue while compiling the following line.
std::string createString();
the error is

"Error: string is not a member of std."

Any idea how to solve this issue? Suggestions are greatly
appreciated.

Thanks
Chakra


Comments

  • stoberstober Posts: 9,765Member ✭✭✭
    : Hi,
    : I'm trying to compile a C++ program on Solaris 2.10 with SUN CC5.5 latest patch level.
    : I'm facing an issue while compiling the following line.
    : std::string createString();
    : the error is
    :
    : "Error: string is not a member of std."
    :
    : Any idea how to solve this issue? Suggestions are greatly
    : appreciated.
    :
    : Thanks
    : Chakra
    :
    :
    :

    [blue]did you include ? [/blue]

  • kchakuskchakus Posts: 8Member
    : : Hi,
    : : I'm trying to compile a C++ program on Solaris 2.10 with SUN CC5.5 latest patch level.
    : : I'm facing an issue while compiling the following line.
    : : std::string createString();
    : : the error is
    : :
    : : "Error: string is not a member of std."
    : :
    : : Any idea how to solve this issue? Suggestions are greatly
    : : appreciated.
    : :
    : : Thanks
    : : Chakra
    : :
    : :
    : :
    :
    : [blue]did you include ? [/blue]
    :
    :

    HI,
    No. I'm not including any header files in that file which is
    throwing this error

    --
    Chakra

  • stoberstober Posts: 9,765Member ✭✭✭
    : HI,
    : No. I'm not including any header files in that file which is
    : throwing this error
    :

    Well then, how in the world do you expect the compiler to know what string is unless you tell it???
Sign In or Register to comment.