Article View: comp.std.c++
Article #2394Re: auto_ptr<T> as function return type
From: David Vandevoorde
Date: Wed, 01 Nov 1995 21:59
Date: Wed, 01 Nov 1995 21:59
24 lines
1327 bytes
1327 bytes
>>>>> "FH" == Fergus Henderson <fjh@munta.cs.mu.OZ.AU> writes: [...] FH> Yep. With the current spec., you need to write FH> auto_ptr<double> p(f().release()); Indeed... and the more I look at it, the more I like it :-P FH> and FH> p.reset(f().release()); ...but here I'm not sure; I think I'd rather see p = f().release(); and do away with the get() member. Daveed [I agree. -fjh.] --- [ comp.std.c++ is moderated. Submission address: std-c++@ncar.ucar.edu. Contact address: std-c++-request@ncar.ucar.edu. The moderation policy is summarized in http://dogbert.lbl.gov/~matt/std-c++/policy.html. ]
Technical Details
Message-ID:
<VANDEVOD.95Nov1111812@avs.cs.rpi.edu>Path:
arc1-ca.pugleaf.net!in2.uu.net!bounce-backReferences:
<47616o$lvr@bcarh8ab.bnr.ca> <VANDEVOD.95Oct31222003@juicer.cs.rpi.edu> <9530600.21749@mulga.cs.mu.OZ.AU>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!in2.uu.net!bounce-back Date: 01 Nov 95 21:59:35 GMT Approved: fjh@cs.mu.oz.au From: vandevod@cs.rpi.edu (David Vandevoorde) Newsgroups: comp.std.c++ Subject: Re: auto_ptr<T> as function return type X-Original-Date: 01 Nov 1995 16:18:12 GMT Organization: RPI Computer Science Message-ID: <VANDEVOD.95Nov1111812@avs.cs.rpi.edu> References: <47616o$lvr@bcarh8ab.bnr.ca> <VANDEVOD.95Oct31222003@juicer.cs.rpi.edu> <9530600.21749@mulga.cs.mu.OZ.AU> In-Reply-To: fjh@munta.cs.mu.OZ.AU's message of 01 Nov 95 13:22:57 GMT X-Auth: PGPMoose V1.1 PGP comp.std.c++ iQBFAgUBMJfuEOEDnX0m9pzZAQE9sAGAjdqJ7zYiQmQyB3jZwDLLxtKFufglKSg6 it5CyB5iJ/ruAmaRGJAu2Rhnkf/ZWcWX =YvUJ