From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on ip-172-31-91-241.ec2.internal X-Spam-Level: X-Spam-Status: No, score=0.0 required=3.0 tests=FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=4.0.1 Path: nntp.eternal-september.org!eternal-september.org!feeder.eternal-september.org!.POSTED!not-for-mail From: Blady Newsgroups: comp.lang.ada Subject: Error: container cannot be indexed with "Cursor" Date: Fri, 8 Aug 2025 22:22:07 +0200 Organization: A noiseless patient Spider Message-ID: <1075m9f$tr0h$1@dont-email.me> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Date: Fri, 08 Aug 2025 20:22:08 +0000 (UTC) Injection-Info: dont-email.me; posting-host="1f750967fca64c8918d7d07be6d5bc31"; logging-data="977937"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19YbUjgGP4pRKp6SHtYRplf" User-Agent: Mozilla Thunderbird Cancel-Lock: sha1:bW6EIIEVxL32gOze8zl7RYQurUY= Content-Language: fr, en-US Xref: feeder.eternal-september.org comp.lang.ada:66861 List-Id: Hello, Container type UX is declared as: type UX is tagged private with Constant_Indexing => Constant_Reference, Variable_Indexing => Reference, Default_Iterator => Iterate, Iterator_Element => Character, Aggregate => (Empty => Empty, Add_Unnamed => Append, New_Indexed => New_Vector, Assign_Indexed => Replace_Element); I declare: S3 : UX; ... 80. for I in S3.Iterate loop 82. if F then 83. S3(I) := 'e'; 84. end if; 85. C := S3 (I); 87. end loop; GNAT 15 issues the errors: test.adb:83:10: error: container cannot be indexed with "Cursor" test.adb:85:14: error: container cannot be indexed with "Cursor" Prior GNAT versions didn't issued any errors. Is there a change in Ada standard? or GNAT? Why is cursor indexing not possible? Thanks for your answers, Pascal.