|
-
January 19th, 2010, 07:34 PM
#11
Re: C++ Smart Pointer Question
 Originally Posted by nuzzle
Admittedly, smart pointers traditionally are used to manage heap allocated objects, but that's only by convention.
Nothing prevents you from having reference counting on stack allocated objects really. It's just that you cannot delete such objects.
I agree and that's very open minded perspective.
Although unrelated to this issue,
I once (when I was a really really newbie xD) tried to design factory pattern without using new.
And most of the members advised against it or thought it cann't be done.
Having had this valuable experience,
I was able keep my focus on addressing the problems the OP had,
rather than simply come out and tell him "it's a bad idea."
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|