المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : const string reference variables



C++ Programming
07-13-2010, 03:50 PM
A const string reference is being passed just as a string to another proc.The code crashes after the call a_proc(). Please give your inputs

Imp::Reset(const string& res_str, const bool& b)
{

a_proc(res_str);
a_get();

}


Imp::a_proc(string res_str)
{
//res_str is just validated
}