Any compiler warning for default copy constructors?
Any compiler warning for default copy constructors?
- Subject: Any compiler warning for default copy constructors?
- From: Scott Fraser <email@hidden>
- Date: Wed, 22 Feb 2006 15:16:31 -0800
Is there a gcc compiler warning that would flag function call arguments
that use a default copy constructor on an object-valued parameter? I
just spent way too much time debugging a problem where I inadvertently
called a function with an object, instead of the address of the object.
The default copy constructor did a shallow copy on entry to the
function. On exit, the destructor did a deep delete, removing the
entire tree that was being pointed to.
Talk about shooting myself in the foot! :-(
Scott
-----
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden