G
Gil
Can anyone see why I'm getting an error with the following code :
void NewData::store(NewDataStruct nd, unsigned long& NewDataID)
{
OtherData.store(nd, NewDataID); // error in this line
// error with NewDataID
}
void OtherData::store(NewDataStruct nd, unsigned long NewDataID)
{
..
..
..
}
error message is :
"src/DataObjects.cpp", line 30: Error: Formal argument _NewDataID of
type unsigned& in call to NewData::store(const NewDataStruct&,
unsigned&) requires an lvalue.
void NewData::store(NewDataStruct nd, unsigned long& NewDataID)
{
OtherData.store(nd, NewDataID); // error in this line
// error with NewDataID
}
void OtherData::store(NewDataStruct nd, unsigned long NewDataID)
{
..
..
..
}
error message is :
"src/DataObjects.cpp", line 30: Error: Formal argument _NewDataID of
type unsigned& in call to NewData::store(const NewDataStruct&,
unsigned&) requires an lvalue.