Login or Sign Up
Logging in...
Remember me
Log in
Or
Sign Up
Forgot password or user name?
Log in with
Search in titles only
Search in C only
Search
Advanced Search
Forums
Product Launch
Updates
Today's Posts
Member List
Calendar
Home
Forum
Topic
C
Why Destructors in C++ can not be overloaded
Collapse
X
Collapse
Posts
Latest Activity
Photos
Page
of
1
Filter
Time
All Time
Today
Last Week
Last Month
Show
All
Discussions only
Photos only
Videos only
Links only
Polls only
Events only
Filtered by:
Clear All
new posts
Previous
template
Next
landoori
New Member
Join Date:
Mar 2008
Posts:
1
#1
Why Destructors in C++ can not be overloaded
Mar 26 '08, 02:08 PM
Hi All,
Can any body tell that
Why Destructors in C++ can not be overloaded
Banfa
Recognized Expert
Expert
Join Date:
Feb 2006
Posts:
9067
#2
Mar 26 '08, 02:20 PM
In what circumstance do you think you would need to be able to overload destructors?
Comment
Post
Cancel
weaknessforcats
Recognized Expert
Expert
Join Date:
Mar 2007
Posts:
9214
#3
Mar 26 '08, 02:50 PM
An object that is going to be destroyed needs only one way of cleaning itself up.
Note also that the destructor has no arguments and no return type to enforce that once it is called, the object is no longer useable.
Comment
Post
Cancel
Previous
template
Next
Working...
Yes
No
OK
OK
Cancel
👍
👎
☕
Comment