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=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail From: "J-P. Rosen" Newsgroups: comp.lang.ada Subject: Re: Redefining "in" "operator" Date: Mon, 5 Feb 2018 17:43:09 +0100 Organization: Adalog Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Date: Mon, 5 Feb 2018 16:59:24 -0000 (UTC) Injection-Info: reader02.eternal-september.org; posting-host="242c2804ce5cef64a6d8a8522196cfbf"; logging-data="26363"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+Np69m3bIAos75bRTmEwVG" User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 In-Reply-To: Content-Language: fr Cancel-Lock: sha1:mZXno2LfDOGdToF/zBF7Dc8vQVc= Xref: reader02.eternal-september.org comp.lang.ada:50307 Date: 2018-02-05T17:43:09+01:00 List-Id: Le 05/02/2018 à 17:26, Alejandro R. Mosteo a écrit : > Are there special reasons not to allow something like that? I think "in" > is not an operator in the Ada RM sense but now I'm curious why the > special treatment. Yes, there is ;-) "in" is not an operator (i.e. a function), it's directly in the syntax (see 4.4). And the reason for that is that the RHS is a membership choice list, not an expression: there is no way you could write a function whose argument is, f.e. a subtype or a range. -- J-P. Rosen Adalog 2 rue du Docteur Lombard, 92441 Issy-les-Moulineaux CEDEX Tel: +33 1 45 29 21 52, Fax: +33 1 45 29 25 00 http://www.adalog.fr