Daniel T.
10/7/2008 11:21:00 PM
In article
<92e08422-9186-4edd-ac49-5287fbb6949d@25g2000prz.googlegroups.com>,
noemailplease0001@gmail.com wrote:
> #ifndef POSITION_H_
> #define POSITION_H_
>
> class Position
> {
> public:
> Position(std::string name, std::string name):
> m_name( name), m_description(description){}
> std::string toString();
> private:
> std::string m_name;
> std::string m_description;
>
> };
>
> #endif /* POSITION_H_ */
>
> I get an error 'error: expected `;' before "m_description"' I don't
> understand that.
>
> Thanks for ur time
>
> -N.E
"ComeauTest.c", line 7: error: name followed by "::" must be a class or
namespace
name... Wild guess: Did you #include the right header?
Position(std::string name, std::string name):
^
"ComeauTest.c", line 7: error: expected a ")"
Position(std::string name, std::string name):
^
"ComeauTest.c", line 7: error: name followed by "::" must be a class or
namespace
name... Wild guess: Did you #include the right header?
Position(std::string name, std::string name):
^
"ComeauTest.c", line 7: error: expected a ";" (perhaps on the previous
statement)
Position(std::string name, std::string name):
^
"ComeauTest.c", line 11: error: name followed by "::" must be a class or
namespace
name... Wild guess: Did you #include the right header?
std::string m_name;
^
"ComeauTest.c", line 12: error: name followed by "::" must be a class or
namespace
name... Wild guess: Did you #include the right header?
std::string m_description;
^
6 errors detected in the compilation of "ComeauTest.c".