From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.5-pre1 (2020-06-20) on ip-172-31-74-118.ec2.internal X-Spam-Level: X-Spam-Status: No, score=-1.9 required=3.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.5-pre1 Date: 15 Aug 93 05:01:54 GMT From: alex@MIMSY.CS.UMD.EDU (Alex Blakemore) Subject: Re: Unconstrained arrays Message-ID: <70375@mimsy.umd.edu> List-Id: In article <9308111642.aa06180@Paris.ics.uci.edu> kanderso@mabillon.ICS.UCI.EDU (Kenneth Anderson) writes: > >> Viewers : str_array(1 .. 1) := (Create("text_artist")); > >>--### A:error: RM 8.3: no visible identifier is of type str_array I dont know about your compiler error, but if what you are trying to do is to create a ragged array of strings AND the array is essentially const ant, I've found it much easier in Ada to define a string valued function than an arr ay. function viewers (index : positive) return string is begin case index is when 1 => return "text_artist"; when 2 => return "another string"; ... the calling code refers only to viewers (i). this way you dont have to do the dynamic allocation yourself, and a smart compiler might put it all on the stack or on a data or even text segment. you dont have to have a dynamic string type or use .all on each reference. of course, this doesnt work as simply if you plan to be able to modify the mapping at run time. -- Alex Blakemore alex@cs.umd.edu NeXT mail accepted -------------------------------------------------------------- "Without an engaged and motivated human being at the keyboard, the computer is just another dumb box." William Raspberry