From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,bf564bb3bcde0817 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!news.glorb.com!news-in.ntli.net!newsrout1-win.ntli.net!ntli.net!border2.nntp.ams.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!feeder2.news.jippii.net!reader1.news.jippii.net!53ab2750!not-for-mail From: Tapio Kelloniemi Subject: Re: Renaming versus initialisation References: <1qys7gc3aqky9$.1qtzg7epyh6kk$.dlg@40tude.net> Newsgroups: comp.lang.ada Message-ID: Date: Wed, 28 Sep 2005 15:12:23 GMT NNTP-Posting-Host: 217.30.176.187 X-Complaints-To: newsmaster@saunalahti.com X-Trace: reader1.news.jippii.net 1127920343 217.30.176.187 (Wed, 28 Sep 2005 18:12:23 EEST) NNTP-Posting-Date: Wed, 28 Sep 2005 18:12:23 EEST Organization: Saunalahti Customer Xref: g2news1.google.com comp.lang.ada:5239 Date: 2005-09-28T15:12:23+00:00 List-Id: "Dmitry A. Kazakov" wrote: >On 27 Sep 2005 20:00:56 -0400, Robert A Duff wrote: > >> Tapio Kelloniemi writes: >> >>> V1 : T := F; >>> V2 : T renames F; >>> >>> I'd like to see an explanation of the effect of an object renaming >>> declaration versus variable declaration and initialisation, when the object >>> being renamed is a return value of a function. Many thanks for it. >> >> They are pretty similar. > >What about difference in respect to creation of new objects? Renaming creates a new object as does initialisation, when not returning by reference (return value is copied = new object is created). -- Tapio