I had a quick question about setting up values for function calls of type_t. In my project I have a parameterized constructor (within a function) of:
ShippingStatus s(location, status, timeUpdated)
and in this class there is a simple get function of
time_t ShippingStatus::m_getTime() {
//TimeUpdated already initialized
return TimeUpdated;
}
Now, the values for location, status, timeUpdated
are all passed-by reference within this main function, and I am attempting to do something like s.m_getTime() = timeUpdated;
but am getting an error of:
expression must be a modifiable lvalue
I was able to do the same operation with location
and status
using similar get functions, but why won't it work with time_t? Is there any way around this?