Suppose I have a class
class Foo {
:
:
}
I have another function
void getf( Foo &f) {
:
:
std::cout<<sizeof f<<std::endl;
}
After I process the data and assign a lot of data to f (vector included in Foo members), I need the size of f object
However, as what I did above, I always get 16, which is the size of a reference here.
Did I do anything wrong? How to do that?
Thanks!