From: "Yannick Duchêne (Hibou57)" <yannick_duchene@yahoo.fr>
Subject: Re: Asis.Text.Character_Position : inconsistency ?
Date: Sun, 07 Nov 2010 20:03:41 +0100
Date: 2010-11-07T20:03:41+01:00 [thread overview]
Message-ID: <op.vltdwfsrule2fv@garhos> (raw)
In-Reply-To: m2k4kpxqfj.fsf@pushface.org
Le Sun, 07 Nov 2010 13:34:56 +0100, Simon Wright <simon@pushface.org> a
écrit:
> GNAT ASIS is pretty clear (at least from the copyright notice) that most
> of the public part of package specs is from the standard.
Gela-ASIS seems too, as the package specification they used is a raw copy
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 in
> the source text, Character_Position is the position in the line.
>
> I suspect you're supposed to use Element_Image, Line_Image etc?
… 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. This
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 or
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 representation
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 list,
just that this would be cleaner… but I don't bother if there is none)
Thanks for your comments :)
--
Si les chats miaulent et font autant de vocalises bizarres, c’est pas pour
les chiens.
“I am fluent in ASCII” [Warren 2010]
next prev parent reply other threads:[~2010-11-07 19:03 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-07 8:04 Asis.Text.Character_Position : inconsistency ? Yannick Duchêne (Hibou57)
2010-11-07 12:34 ` Simon Wright
2010-11-07 19:03 ` Yannick Duchêne (Hibou57) [this message]
2010-11-07 19:18 ` Simon Wright
2010-11-07 19:35 ` J-P. Rosen
2010-11-12 19:35 ` Randy Brukardt
2010-11-07 19:20 ` Simon Wright
2010-11-07 20:44 ` Yannick Duchêne (Hibou57)
2010-11-09 14:18 ` Vadim Godunko
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox