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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,3ccb707f4c91a5f2 X-Google-Attributes: gid103376,public From: geert@fozzie.sun3.iaf.nl (Geert Bosch) Subject: Re: Java vs Ada 95 (Was Re: Once again, Ada absent from DoD SBIR solicitation) Date: 1996/11/16 Message-ID: <56kt98$6at@fozzie.sun3.iaf.nl>#1/1 X-Deja-AN: 196982085 references: <325BC3B3.41C6@hso.link.com> <55gkch$gg6@fozzie.sun3.iaf.nl> <1996Nov4.072757.1@eisner> organization: La Calandre Infortunee newsgroups: comp.lang.ada Date: 1996-11-16T00:00:00+00:00 List-Id: Robert Dewar wrote: "If you are using reference counts for unbounded strings, then it is indeed the case that the code manipulating these refrence counts is highly likely to be erroneous (wrt the reference counts as shared variables), if there is any sharing of string values between tasks." [example deleted] "Well this program execution may be erroneous, which is at least to me a bit of a surprise." It is a suprise, because the user of the Unbounded_String package would not expect that the package body contains code that may lead to erroneous execution. A correct and efficient implementation of the Unbounded_String package is easy if the system provides Test_And_Increment and Decrement_And_Test, where the Test tests wether the value is zero. Both of these primitives can be implemented easily using Test_And_Set. -- E-Mail: geert@sun3.iaf.nl