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,505b52f527b29fd6,start X-Google-Attributes: gid103376,public From: Gordon Dodrill Subject: Are there any "bad" Ada constructs? Date: 1996/09/04 Message-ID: <322E16DC.74B1@swcp.com>#1/1 X-Deja-AN: 178540198 content-type: text/plain; charset=us-ascii organization: Southwest Cyberport mime-version: 1.0 newsgroups: comp.lang.ada x-mailer: Mozilla 2.01Gold (Win95; I) Date: 1996-09-04T00:00:00+00:00 List-Id: The C and C++ language have several constructs that are undefined enough that two conforming compilers are permitted to give different results and still be correct. One example is, i = 2; a[i] = i++; Executing the second of these two statements, assuming they are properly declared first, a compiler is permitted to assign the value of 2 to either a[2] or a[3] and be correct. This construct is stated to be undefined by the ANSI-C standard, and any compiler can actually do anything it pleases. I saw one reference that stated there are 150 of these sorts of things in C and C++. My question is: Are there any constructs in Ada that are permitted to do two or more different things and still be correct, in a manner that is similar to that listed above? Thanks, Gordon // Coronado Enterprises Tutorials - Ada, C, C++, Pascal // Learn to program in a modern language // All are available at http://www.swcp.com/~dodrill // Gordon Dodrill - dodrill@swcp.com