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.2 required=5.0 tests=BAYES_00,INVALID_MSGID, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,9122cfe7284630ab X-Google-Attributes: gid103376,public From: fd@piau () Subject: Re: A question about v'range...? Date: 1997/01/09 Message-ID: <5b29ku$o93@news.cict.fr>#1/1 X-Deja-AN: 208654223 references: organization: DULUC Franck at Aerospatiale Toulouse reply-to: franck.duluc@avions.aerospatiale.fr newsgroups: comp.lang.ada Date: 1997-01-09T00:00:00+00:00 List-Id: eranshap@netvision.net.il wrote: : Hi All, : I have the following program: : --BEGINNING OF PROGRAM : with Ada.Text_IO; : procedure taskmain is : NUM_OF_ELEMENTS : constant Integer := 100; : NUM_OF_TASKS : constant Integer := 10; : : type array_type is array (Integer range <>) of Positive; : : procedure Find_primes (vector : in array_type; num : in Positive) is : : ...... : --END OF PROGRAM : And I get this output: : 1 : 1 : 100 : 2 : 1 : 100 : 3 : 1 : 100 : 4 : 1 : ............ : This means that vector'range inside the task Manage is 1..9, while : vector'first is 1, and vector'last is 100, as printed. : I can also add, that when I did the same printing with the taskmain : procedure, it computed it correctly, i.e. vect'range is 1..100. : Why does this happen? : What can I do to correct it? I think you've got a problem with your Ada developpment system, the code that has been generated looks false, this is not normal. There is no Ada Standard explanation. -- \\\|||/// DULUC Franck . ======= / \| O O | Aerospatiale / IRIT \ / \`___'/ # _| |_ franck.duluc@avions.aerospatiale.fr (#) ( ) #\//|* *|\\ Tel: 33 - 05 61 18 19 16 #\/( * )/ # ===== Fax: 33 - 05 61 93 86 04 # ( _ ) # || || 316, route de Bayonne. 31060 TOULOUSE Cedex 03 .#---'| |`----. `#----' `-----' FRANCE