From: mfb@mbunix.mitre.org (Michael F Brenner)
Subject: Re: How to perform bit-wise xor, and...?
Date: 1996/11/24
Date: 1996-11-24T00:00:00+00:00 [thread overview]
Message-ID: <579n3q$r99@top.mitre.org> (raw)
In-Reply-To: 1996Nov22.105049.1@eisner
Larry said:
> ... let me just comment that when you declare something as an
> integer it specifies the manner in which you intend to use it.
> If you find you have a need to apply logical operations to a numeric,
> then either:
> 1) You were wrong to declare it as an integer
>or
> 2) Some external definition has horribly overloaded the
> meaning of a given location*
I would like to add a third possibility:
3) There is nothing wrong with using XOR or other operators on
exact numbers, and Ada has been upgraded to Ada-95 which
allows those operators on a kind of exact number known as
modular types. Ada-83 permitted these operators by means
of library packages, but these operators were not built
into the language for exact types. To use the Ada-95
operators, download or purchase an Ada-95 compiler, and
declare your variables of a type like this:
type exacts is mod 2**8;
next prev parent reply other threads:[~1996-11-24 0:00 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
1996-11-22 0:00 How to perform bit-wise xor, and...? Leong San Io Francisco
1996-11-22 0:00 ` Matthew Heaney
1996-11-24 0:00 ` Brian
1996-11-27 0:00 ` Robert Dewar
1996-11-22 0:00 ` Larry Kilgallen
1996-11-23 0:00 ` Leong San Io Francisco
1996-11-24 0:00 ` Michael F Brenner [this message]
1996-11-25 0:00 ` Robert I. Eachus
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox