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,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 Path: buffer1.nntp.dca1.giganews.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!newspeer1.nac.net!feeder.erje.net!eu.feeder.erje.net!news.etla.org!aioe.org!.POSTED!not-for-mail From: Victor Porton Newsgroups: comp.lang.ada Subject: Re: Lazy evaluation Date: Tue, 23 Sep 2014 15:01:29 +0300 Organization: Aioe.org NNTP Server Message-ID: References: <85idneIsZeZHqYHJRVn_vwA@giganews.com> <11up8h3pwcwf$.1tmy4g7sb6csv$.dlg@40tude.net> NNTP-Posting-Host: eoFKaNinZfc2iCCySkk0UQ.user.speranza.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7Bit X-Complaints-To: abuse@aioe.org User-Agent: KNode/4.14 X-Notice: Filtered by postfilter v. 0.8.2 Xref: number.nntp.dca.giganews.com comp.lang.ada:189104 Date: 2014-09-23T15:01:29+03:00 List-Id: Dmitry A. Kazakov wrote: > Consider the problem of evaluation order: > > X : String := String'Input (File) & String'Input (File); -- Ill > defined! I don't understand why it's ill defined. Please explain. > Now, let "&" be lazy in the right argument: > > function "&" (Left : String; Right : lazy String) return String; > > In my opinion, it is not laziness which causes problems, but more the > closures. If closures were limited in some reasonable (from Ada's POV) > way, then laziness would be not an issue. -- Victor Porton - http://portonvictor.org