I'm getting following compile error
OrderedList.cc: In member function `std::string OrderedList::find(std::string&, std::string&, int&)':
OrderedList.cc:133: error: invalid conversion from `int' to `const char*'
OrderedList.cc:133: error: initializing argument 1 of `std::basic_string<_CharT, _Traits, _Alloc>::basic_string(const _CharT*, const _Alloc&) [with _CharT = char, _Traits = std::char_traits<char>, _Alloc = std::allocator<char>]'
OrderedList.cc looks like this
string OrderedList::find(string& w, string& d, int& s)
{
keyValue* p = head;
if(p != NULL)
{
w = p->word;
d = p->definition;
head = p->next;
if(head == NULL)
{
s = 0;
return(w, d, s);
}
else
{
return(w, d, 1);
}
}//end p !=NULL
else
{
return(w, d, 0);
}
}//end find
and its called by following function
void dynamicHTable::sorted()
{
string word = NULL;
string definition = NULL;
int status = 0;
for(int i = 0; i < TABLE_SIZE-1; i++)
{
dHTable[i].find( word, definition, status);
if (status ==1)
{
do{
Table.insert(word, definition);
dHTable[i].find( word, definition, status);
}while(status ==1);
}//if ebd
}//for end
}//sorted end