From: "Yannick Duchêne (Hibou57)" <yannick_duchene@yahoo.fr>
Subject: Asis.Text.Character_Position : inconsistency ?
Date: Sun, 07 Nov 2010 09:04:11 +0100
Date: 2010-11-07T09:04:11+01:00 [thread overview]
Message-ID: <op.vlsjc9q2ule2fv@garhos> (raw)
Hello Ada writers,
I was trying to patch AdaControl ( http://www.adalog.fr/adacontrol2.htm )
so that it can build with Gela-ASIS. This is an interesting process of
little refactorisation, as Gela-ASIS is clearly design so that it make no
reference at all to a specific compiler implementation (it do so defining
an Implementation_Defined_Type from which other discrete types are
derived). After a first attempt I restarted again and felt something was
wrong as I could not get something coherent about types.
Prior note: I do not own a copy of the ISO ASIS reference, so I cannot
tell who of TenDRA or ISO is right or wrong.
What disturbs me, if I believe (as I feel it is) that Gela-ASIS heavily
stick on the ASIS standard: Asis.Text defines two types,
Character_Position and Line_Number. Character_Position is derived from
ASIS_Natural, which in turn is derived from ASIS_Integer, which, the
latter, is implementation defined.
Also, Asis defines a type Asis.Program_Text, which is not implementation
defined, and which is explicitly an unconstrained subtype of the Ada's
type Standard.Wide_String.
Shouldn't be Asis.Text.Character_Position be defined so that is can be
used as an index in Asis.Program_Text ? This would imply
Character_Position would be a derived from Standard.Positive, and due to
the way Character_Position is derived, as explained above, this would
imply the root implementation defined type, should be instead, at least
derived from Positive or an ancestor type of Positive.
Which is wrong ? TenDRA with Gela-ASIS or the ASIS ISO reference (which I
do not own, so I cannot check).
Comments and lightings welcome from any one owning a copy of the ASIS
reference, so that I can figure if I should primarily patch Gela-ASIS or
AdaControl.
With thanks
next reply other threads:[~2010-11-07 8:04 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-07 8:04 Yannick Duchêne (Hibou57) [this message]
2010-11-07 12:34 ` Asis.Text.Character_Position : inconsistency ? Simon Wright
2010-11-07 19:03 ` Yannick Duchêne (Hibou57)
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