🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c++
Article #4089

Re: Temporary objects in Std

#4089
From: David Vandevoorde
Date: Wed, 17 Apr 1996 18:45
27 lines
1362 bytes
>>>>> "WP" == Wei Peng <peng@dpg.rnb.com> writes:
[...]
WP> void doSomething(const char*);

WP> String getString();

WP> const char* getCharStar()
WP> {
WP>   return returnString();
WP> }

WP> Now if we do:

WP>           doSomething(getCharStar());
[...]

You'll need to explain what returnString() does...

	Daveed



[ 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         ]
[ FAQ:      http://reality.sgi.com/employees/austern_mti/std-c++/faq.html    ]
[ Policy:   http://reality.sgi.com/employees/austern_mti/std-c++/policy.html ]
[ Comments? mailto:std-c++-request@ncar.ucar.edu                             ]
Technical Details
Message-ID: <xsospe2vgru.fsf@avs.cs.rpi.edu>
Path: arc1-ca.pugleaf.net!engnews1.Eng.Sun.COM!taumet!clamage
References: <4107cc$101229.223@news>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!engnews1.Eng.Sun.COM!taumet!clamage
From: vandevod@cs.rpi.edu (David Vandevoorde)
Newsgroups: comp.std.c++
Subject: Re: Temporary objects in Std
Date: 17 Apr 1996 18:45:53 GMT
Organization: RPI Computer Science
Sender: vandevod@avs.cs.rpi.edu
Approved: clamage@eng.sun.com (comp.std.c++)
Message-ID: <xsospe2vgru.fsf@avs.cs.rpi.edu>
References: <4107cc$101229.223@news>
NNTP-Posting-Host: taumet.eng.sun.com
X-Nntp-Posting-Host: avs.cs.rpi.edu
In-Reply-To: peng@dpg.rnb.com's message of 17 Apr 1996 14:57:29 GMT
X-Newsreader: Gnus v5.1
Content-Length: 318
X-Lines: 20
Originator: clamage@taumet