F
fcvcnet
Hi,
CarPtr g()
{
CarPtr p(new Car()); <-- How to explain this
// ...
return p;
}
Thanks.
CarPtr g()
{
CarPtr p(new Car()); <-- How to explain this
// ...
return p;
}
Thanks.
fcvcnet said:Hi,
CarPtr g()
{
CarPtr p(new Car()); <-- How to explain this
fcvcnet said:Hi,
CarPtr g()
{
CarPtr p(new Car()); <-- How to explain this
// ...
return p;
}
benben said:CarPtr is a class.
The above statement constructs a CarPtr object named p with a parameter
that is a raw pointer to a dynamically allocated Car object.
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.