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,243dc2fb696a49cd X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news2.google.com!fu-berlin.de!uni-berlin.de!not-for-mail From: "Dmitry A. Kazakov" Newsgroups: comp.lang.ada Subject: Re: Ada Popularity: Comparison of Ada/Charles with C++ STL (and Perl) Date: Mon, 27 Sep 2004 10:29:25 +0200 Message-ID: References: <41547dae$0$91007$39cecf19@news.twtelecom.net> <0b%4d.2815$M45.1912@trndny09> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: news.uni-berlin.de DXj3CuSJ6aHbo4ZI+Up4/AnVAtM3KaudhmIXWGwGaUlenPoHA= User-Agent: 40tude_Dialog/2.0.12.1 Xref: g2news1.google.com comp.lang.ada:4248 Date: 2004-09-27T10:29:25+02:00 List-Id: On Fri, 24 Sep 2004 20:10:36 GMT, Frank J. Lhota wrote: > "Matthew Heaney" wrote in message > news:41547dae$0$91007$39cecf19@news.twtelecom.net... >> Note that (as Randy alluded to) there's still a chance the ARG will add >> something like reference types to Ada. It would be declared something >> like: >> >> function Update_Element >> (Container : in Map; >> Key : in Key_Type) return access Element_Type; >> >> Then you could say: >> >> Update_Element (M, K).all := 42; > > I still like the idea of adding "()" and "():=" operators to Ada. "():=" could be problematic in Y(I).Foo(Baz):=Bar. I think it should better be an in-place "()" and ":=". > Then you could say: > > M(K) := 42; > > This is clearer, and it makes absolutely no assertions as to how containers > represent their elements. Yes. And I agree with Randy Brukardt, that a library should avoid using access types. -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de