J
Jan-Henrik Grobe
Hallo,
I am searching for helpü with non-pod objects. I have a class X which
contains an object y of class Y as a member. This object is non-pod. Now I
have an object x from class X and want to isolate the object y out of it. I
tried it with adding a get-fucntion.
Y X::getObjectY(void)
{
return y;
}
In my main program I create an Y object where I want to store the result of
that function.
Y myy;
....
myy = x->getObjectY();
Now gcc (I use Fedora Core 2.0) plays wild boar and comes with an error
message like this: "object y is non-pod. assignment will be aborted during
runtime". In result I dont have y copied in myy. But that is what I want
because I want to send myy over a network.
Does anyone had this problem before and know how to solve it.
Many thanks
Jan
I am searching for helpü with non-pod objects. I have a class X which
contains an object y of class Y as a member. This object is non-pod. Now I
have an object x from class X and want to isolate the object y out of it. I
tried it with adding a get-fucntion.
Y X::getObjectY(void)
{
return y;
}
In my main program I create an Y object where I want to store the result of
that function.
Y myy;
....
myy = x->getObjectY();
Now gcc (I use Fedora Core 2.0) plays wild boar and comes with an error
message like this: "object y is non-pod. assignment will be aborted during
runtime". In result I dont have y copied in myy. But that is what I want
because I want to send myy over a network.
Does anyone had this problem before and know how to solve it.
Many thanks
Jan