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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: "G.B." Newsgroups: comp.lang.ada Subject: qualified expressions acting as names - not accepted? Date: Sun, 21 Aug 2016 17:56:41 +0200 Organization: A noiseless patient Spider Message-ID: Reply-To: nonlegitur@futureapps.de Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Date: Sun, 21 Aug 2016 15:56:41 -0000 (UTC) Injection-Info: mx02.eternal-september.org; posting-host="d0523a3331cd48db2ac6213ee96363c9"; logging-data="6767"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18g7GRFmXoaeNqelXpX27SMe1e0azZOEhM=" User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 X-Mozilla-News-Host: news://news.arcor.de:119 Cancel-Lock: sha1:6Y28lyRPXe33vd0lKd9xXjIfN2o= Xref: news.eternal-september.org comp.lang.ada:31483 Date: 2016-08-21T17:56:41+02:00 List-Id: The compiler accepts line (1) below, but neither (2) or (3). It says it is expecting Standard.Integer, not Standard.Boolean. Is this a bug in the program or bug in the compiler? (String'("AZ")(1) in a similar program is accepted.) procedure Qualified is type S is array (Boolean) of Character; X: Character; Z: constant S := "AZ"; begin X := Z (False); -- (1) X := S'(Z) (False); -- (2) X := S'("AZ")(False); -- (3) end; -- "HOTDOGS ARE NOT BOOKMARKS" Springfield Elementary teaching staff