std::string::size() const

This is a discussion on std::string::size() const within the C++ Programming forums, part of the General Programming Boards category; When I try to compile my program I get this: [Linker error] undefined reference to `std::string::size() const' What could be ...

  1. #1
    Registered User
    Join Date
    Jun 2006
    Posts
    10

    std::string::size() const

    When I try to compile my program I get this:
    [Linker error] undefined reference to `std::string::size() const'

    What could be wrong, feels like this is a easy-to-fix error?
    Thx!

  2. #2
    pronounced 'fib' FillYourBrain's Avatar
    Join Date
    Aug 2002
    Posts
    2,297
    are you compiling with gcc instead of g++? you can link the stdC++ library stuff to fix the problem
    "You are stupid! You are stupid! Oh, and don't forget, you are STUPID!" - Dexter

  3. #3
    The superhaterodyne twomers's Avatar
    Join Date
    Dec 2005
    Location
    Ireland
    Posts
    2,262
    Code?

  4. #4
    Registered User
    Join Date
    Jun 2006
    Posts
    10
    Quote Originally Posted by FillYourBrain
    are you compiling with gcc instead of g++? you can link the stdC++ library stuff to fix the problem
    That worked fine, thx a bunch!

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Polynomials and ADT's
    By Emeighty in forum C++ Programming
    Replies: 20
    Last Post: 08-19-2008, 09:32 AM
  2. Undefined Reference Compiling Error
    By AlakaAlaki in forum C++ Programming
    Replies: 1
    Last Post: 06-27-2008, 12:45 PM
  3. Drawing Program
    By Max_Payne in forum C++ Programming
    Replies: 21
    Last Post: 12-21-2007, 05:34 PM
  4. Certain functions
    By Lurker in forum C++ Programming
    Replies: 3
    Last Post: 12-26-2003, 01:26 AM
  5. Half-life SDK, where are the constants?
    By bennyandthejets in forum Game Programming
    Replies: 29
    Last Post: 08-25-2003, 12:58 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21