comp.lang.ada
 help / color / mirror / Atom feed
From: Marin David Condic <mcondic.nospam@acm.org>
Subject: Re: S'Write and How To Count Bytes
Date: 2000/10/07
Date: 2000-10-07T14:28:45+00:00	[thread overview]
Message-ID: <39DF3347.38C82563@acm.org> (raw)
In-Reply-To: 3A061E9A.B8F76112@telepath.com

Ted Dennison wrote:

> OK. I went and checked out the nifty new ARM in PDF form (html doesn't have
> page numbers, presumably due to the formatting limitations of html). Here's
> what it says:
>
>      {8652/0040} For every subtype S of a language-defined nonlimited
>      specific type T, the output generated by S'Output or S'Write shall
>      be readable by S'Input or S'Read, respectively. This rule applies
>      across partitions if the implementation conforms to the
>      Distributed Systems Annex.
>      36.1/1
>
> Now just reading this cold, I would have figured that "language-defined
> type" meant types defined by the language itself (eg: Integer), rather than
> defined in a package (eg: System.Address or
> Ada.Strings.Unbounded.Unbounded_String). Thus this passage really wouldn't
> have anything to say about the workability of Unbounded_String'Write.
>

That's not the way I would read it if I were the Judge in Language Court. (Idea
for a new T.V. series? Move over Judge Judy!)

If I were the Judge, my legislating from the bench would go like this: "You
guys wrote this ARM. The ARM defines the Ada language. The packages in the
annexes are thus part of the Ada Language. Unbounded_String is a non-limited
type in a language defined package (same as standard). Hence 36.1/1 implies
that when 'Output is called, you can't just dump 32 bits of pointer into the
stream - you've got to implement a 'Output that will write the contents of the
Unbounded_String into the stream such that on 'Input you get back the string.
Your unfunded mandate is to now go off and change your compilers."

But of course, one must now ask what the implications are for 'Read and 'Write?
Would they have to output the contents of the Unbounded_String? (Granted,
you're on your own with respect to the length, but would it be required to
treat the string properly?)

MDC
--
======================================================================
Marin David Condic - Quadrus Corporation - http://www.quadruscorp.com/
Send Replies To: m c o n d i c @ q u a d r u s c o r p . c o m
Visit my web site at:  http://www.mcondic.com/

    "Giving money and power to Government is like giving whiskey
    and car keys to teenage boys."

        --   P. J. O'Rourke
======================================================================






  parent reply	other threads:[~2000-10-07  0:00 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-09-30  0:00 S'Write and How To Count Bytes Marin David Condic
2000-10-01  0:00 ` David C. Hoos, Sr.
2000-10-02  0:00   ` Marin David Condic
2000-10-02  0:00     ` Ted Dennison
2000-10-02  0:00       ` tmoran
2000-10-02  0:00         ` tmoran
2000-10-02  0:00           ` Ted Dennison
2000-10-02  0:00           ` Marin David Condic
2000-10-11  0:00             ` Nick Roberts
2000-10-11  0:00               ` Marin David Condic
2000-10-02  0:00         ` Marin David Condic
2000-10-03  0:00       ` Robert A Duff
2000-10-06  0:00         ` Randy Brukardt
2000-10-07  0:11           ` Ted Dennison
2000-10-06  0:00             ` Randy Brukardt
2000-10-07  0:00             ` Marin David Condic [this message]
2000-10-08  0:00               ` Jean-Pierre Rosen
2000-10-09  0:00                 ` Randy Brukardt
2000-10-11  0:00                 ` Marin David Condic
2000-10-02  0:00   ` Dr. Joachim Schr�er
2000-10-02  0:00     ` Marin David Condic
2000-10-06  0:00       ` Charles Hixson
2000-10-02  0:00 ` David C. Hoos, Sr.
2000-10-02  6:58 ` tmoran
2000-10-02  0:00   ` Marin David Condic
  -- strict thread matches above, loose matches on Subject: below --
2000-10-02  0:00 tmoran
2000-10-03  5:21 ` Marin David Condic
2000-10-03  0:00 Mario Amado Alves
2000-10-03  0:00 ` Marin David Condic
replies disabled

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