home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!usc!elroy.jpl.nasa.gov!swrinde!mips!mips!munnari.oz.au!metro!extro.ucc.su.OZ.AU!maxtal
- From: maxtal@extro.ucc.su.OZ.AU (John MAX Skaller)
- Newsgroups: comp.lang.c++
- Subject: Re: destruction of temporaries
- Message-ID: <1992Aug14.233026.7827@ucc.su.OZ.AU>
- Date: 14 Aug 92 23:30:26 GMT
- References: <46140@sunquest.UUCP> <rmartin.713716434@thor>
- Sender: news@ucc.su.OZ.AU
- Organization: MAXTAL P/L C/- University Computing Centre, Sydney
- Lines: 19
- Nntp-Posting-Host: extro.ucc.su.oz.au
-
- In article <rmartin.713716434@thor> rmartin@thor.Rational.COM (Bob Martin) writes:
- >
- >Whenever you provide a regular copy constructor, you are granting
- >permission to the compiler to make temporaries. This must be a
- >conscious choice, and must be supported by construction and
- >destruction semantics which are valid in any context.
- >
-
- Obvious but I'd never thought of it this way before.
- Interestingly my originating post on GC was stimulated by the idea
- that the lifetime of temporaries problem can be solved by garbage
- collecting them. Then they last as long as necessary.
-
-
- --
- ;----------------------------------------------------------------------
- JOHN (MAX) SKALLER, maxtal@extro.ucc.su.oz.au
- Maxtal Pty Ltd, 6 MacKay St ASHFIELD, NSW 2131, AUSTRALIA
- ;--------------- SCIENTIFIC AND ENGINEERING SOFTWARE ------------------
-