comp.lang.ada
 help / color / mirror / Atom feed
From: dewar@cs.nyu.edu (Robert Dewar)
Subject: Re: Ada + Multi-Byte/Wide Chars = Modern Language?
Date: 1 Feb 1995 07:13:27 -0500
Date: 1995-02-01T07:13:27-05:00	[thread overview]
Message-ID: <3gntt7$8dg@gnat.cs.nyu.edu> (raw)
In-Reply-To: 1995Jan29.171712.4531@midway.uchicago.edu

Richard Goerwitz says:

>In R. William Beckwith writes:
>>
>>    -- The declaration of type Wide_Character is based on the standard
>>    -- ISO 10646 BMP character set.  The first 256 positions have the
>>    -- same contents as type Character.  See 3.5.2.
>        ^^^^^^^^^^^^^
>
>What is meant by "same contents"?  There are several multi-byte and wide
>character standards.  By using the word "contents" here is the standard
>implying that type Character is assumed to encode specific glyphs?

Yes, there are several multi-byte and wide character standards, but what's
that got to do with it? As Bill (and the RM!) make clear, Ada uses the
ISO 10646 BMP standard, which is identical to Unicode. The first 256
character positions of the BMP set correspond to Latin-1, which is what
type Character in Ada is. i.e the ansswer to your question is that not
only is the Standard "implying" the encoding of specific glyphs, it is
in a sense requiring it.

Of course in practice there are no language semantics that depend on the
specific glyphs, so a given Ada compiler can be used in an environment
with a quite different set of glyphs.

In addition, Ada compilers are free to provide alternative localizations
of the definition of Character and/or Wide_Character. For example, in
GNAT there is a switch gnati with the following settings:

  -gnati1   Latin-1 (the standard setting)
  -gnati2   Latin-2
  -gnati3   Latin-3
  -gnati4   Latin-4
  -gnatip   IBM-PC character set
  -gnatif   Full upper half allowed in identifiers with no case equivalence
  -gnatin   No upper half characters allowed in identifiers
  -gnatiw   Wide characters allowed in identifiers

These settings govern the set of characters that are accepted in identifiers,
and the definition of upper-lower case correspondence. For detailed definitions
of these character sets, see the source of package Csets in the GNAT sources.





  parent reply	other threads:[~1995-02-01 12:13 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1995-01-23 18:32 Ada + Multi-Byte/Wide Chars = Modern Language? Richard L. Goerwitz
1995-01-24 19:28 ` Robert Dewar
1995-01-26 12:56   ` Gentle
1995-01-28  1:56     ` R. William Beckwith
1995-01-29 17:17       ` Richard L. Goerwitz
1995-01-30 17:27         ` Vincent Broman
1995-02-01 12:13         ` Robert Dewar [this message]
1995-02-02  2:53         ` Tucker Taft
     [not found]   ` <1995Jan27.040708.22494@midway.uchicago.edu>
1995-01-28 18:30     ` Robert Dewar
1995-01-26  3:36 ` R. William Beckwith
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox