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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,50dfc152dc561349 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,UTF8 Path: g2news1.google.com!news3.google.com!feeder.news-service.com!94.75.214.39.MISMATCH!aioe.org!not-for-mail From: =?utf-8?Q?Yannick_Duch=C3=AAne_=28Hibou57?= =?utf-8?Q?=29?= Newsgroups: comp.lang.ada Subject: Re: Asis.Text.Character_Position : inconsistency ? Date: Sun, 07 Nov 2010 20:03:41 +0100 Organization: Ada @ Home Message-ID: References: NNTP-Posting-Host: DiGLPd43lnw8JsA8Yc5Vdg.user.speranza.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed; delsp=yes Content-Transfer-Encoding: Quoted-Printable X-Complaints-To: abuse@aioe.org X-Notice: Filtered by postfilter v. 0.8.2 User-Agent: Opera Mail/10.63 (Win32) Xref: g2news1.google.com comp.lang.ada:15376 Date: 2010-11-07T20:03:41+01:00 List-Id: Le Sun, 07 Nov 2010 13:34:56 +0100, Simon Wright a = = =C3=A9crit: > GNAT ASIS is pretty clear (at least from the copyright notice) that mo= st > of the public part of package specs is from the standard. Gela-ASIS seems too, as the package specification they used is a raw cop= y = of what you can get from there: http://www.sigada.org/wg/asiswg/intro.html > ASIS.Text is about fragments of code -- the part of the source text > corresponding to an element -- in type Span. Line_Number is the line i= n > the source text, Character_Position is the position in the line. > > I suspect you're supposed to use Element_Image, Line_Image etc? =E2=80=A6 and Comment_Image and Non_Comment_Image and Debug_Image, Yes. = But the = source I am dealing do the assumption Character_Position is a subtype of= = Natural, and that is why I was wondering about this type definition. Thi= s = leads into trouble when I try to build it with Gela-ASIS, because with = Gela-ASIS, Character_Position and Line_Number are not subtypes (direct o= r = indirect) of Natural. As the packages specifications seems to be raw copy of what you get from= = the link above, I suppose TenDRA is right. And you are right too, the accessors to be used to get text representati= on = are indeed the Asis.Text.XTZ_Image. So there is no need for = Character_Position to be a subtype of the index type of Program_Text. So= = the Asis specification is not wrong neither. By the way, another question: do you know a link to a working draft = version of ASIS 2005 ? (I know this can be inferred from ASIS Issues lis= t, = just that this would be cleaner=E2=80=A6 but I don't bother if there is = none) Thanks for your comments :) -- = Si les chats miaulent et font autant de vocalises bizarres, c=E2=80=99es= t pas pour = les chiens. =E2=80=9CI am fluent in ASCII=E2=80=9D [Warren 2010]