From -3810395890805000791
X-Google-Thread: f78e5,49ee1c3b487069d,start
X-Google-Attributes: gidf78e5,public
X-Google-Language: ENGLISH,ASCII-7-bit
Path: g2news2.google.com!news1.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!local01.nntp.dca.giganews.com!nntp.speakeasy.net!news.speakeasy.net.POSTED!not-for-mail
NNTP-Posting-Date: Wed, 13 Dec 2006 12:50:11 -0600
Return-Path: <devnull@stump.algebra.com>
X-Authentication-Warning: mulga.csse.unimelb.edu.au: fjh set sender to devnull@stump.algebra.com using -f
X-Robomod: STUMP, ichudov@algebra.com (Igor Chudov)
X-Original-To: std-c++@mailman.ucar.edu
Delivered-To: std-c++@mailman.ucar.edu
From: "Javier" <ljestrada@developeer.com>
Newsgroups: comp.std.c++
Subject: What is the rationale behind std::tr1::enable_shared_from_this?
Organization: http://groups.google.com
Message-ID: <1166035229.485959.60700@16g2000cwy.googlegroups.com>
Mime-Version: 1.0
Content-Type: text/plain; charset="iso-8859-1"
X-Complaints-To: groups-abuse@google.com
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1) Gecko/20061010 Firefox/2.0,gzip(gfe),gzip(gfe)
X-HTTP-Via: 1.1 barracuda.peinc.com:8080 (http_scan/1.1.2.5.10)
Complaints-To: groups-abuse@google.com
Injection-Info: 16g2000cwy.googlegroups.com; posting-host=67.151.52.10;
   posting-account=ztm1gw0AAAAijbdPz6ORWdTxlAbUL-Bv
X-Virus-Scanned: amavisd-new at ucar.edu
X-Virus-Scanned: amavisd-new at csse.unimelb.edu.au
Approved: Fergus Henderson <fjh@cs.mu.oz.au>, moderator of comp.std.c++
X-Virus-Scanned: amavisd-new at csse.unimelb.edu.au
Date: Wed, 13 Dec 2006 12:42:38 CST
Lines: 21
NNTP-Posting-Host: 65.182.171.162
X-Trace: sv3-tsTbnRtqaS3SlY29ivj0PR2iY3H1lViCy2IRSOP1Qw1mrzwgX1QWcAE7YEVJ1aBQUVmJ75c+pqyWgbk!3i93WPPMuU15a2eXUX2zZngLijfN2CSED2vMgc/uYLgsZHrBPPWRZ0DFLX9boF+SYBEN4eQybKU7!9hSm8NI8GKrH9L+XWY2QGNqktZUWuXUy9dnvqpoO
X-Complaints-To: abuse@speakeasy.net
X-DMCA-Complaints-To: abuse@speakeasy.net
X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers
X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly
X-Postfilter: 1.3.32
Xref: g2news2.google.com comp.std.c++:5050

I'm trying to find the rationale behind this class beyond the Boost
documentation
(http://www.boost.org/libs/smart_ptr/sp_techniques.html#from_this) and
Pete Becker's C++ Standard Library Extensions book (section 2.6, pp
57).

I understand the technicalities of the class, but what are some
practical uses?  Are there any "gotchas"?  It would seem to me that
once a class is "smartified" there are implications in a design
regarding its lifetime.

Regards,

Javier

---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.comeaucomputing.com/csc/faq.html                      ]



