U
uday.sen
Hi,
I am porting a piece of code from VC++ to linux platform. My compiler
is g++ 3.2.2. I am getting following error:
no matching function for call to A::setResponse(std::wstring)
candidates are A::setResponse(std::wstring &) ---> This is
indeed the signature
I am using this function as:
std::wstring A::getXMLStr()
{
std::wstring str = /* get a string from XML attribute */
return str;
}
A::setResponse(std::wstring &str)
{
this->response = str;
}
A::sendMsg()
{
this->setResponse(this->getXMLStr());
}
Can anybody please tell me whether this problem is becasue copy
constructor of std::wstring is explicit? Is this problem been fixed in
recent gcc? In that case in which version of gcc this problem is fixed?
Thanks and regards,
- Uday
I am porting a piece of code from VC++ to linux platform. My compiler
is g++ 3.2.2. I am getting following error:
no matching function for call to A::setResponse(std::wstring)
candidates are A::setResponse(std::wstring &) ---> This is
indeed the signature
I am using this function as:
std::wstring A::getXMLStr()
{
std::wstring str = /* get a string from XML attribute */
return str;
}
A::setResponse(std::wstring &str)
{
this->response = str;
}
A::sendMsg()
{
this->setResponse(this->getXMLStr());
}
Can anybody please tell me whether this problem is becasue copy
constructor of std::wstring is explicit? Is this problem been fixed in
recent gcc? In that case in which version of gcc this problem is fixed?
Thanks and regards,
- Uday