comp.lang.ada
 help / color / mirror / Atom feed
From: jerry@jvdsys.nextjk.stuyts.nl (Jerry van Dijk)
Subject: Re: And
Date: 1998/07/22
Date: 1998-07-22T00:00:00+00:00	[thread overview]
Message-ID: <EwI7CC.5t@jvdsys.nextjk.stuyts.nl> (raw)
In-Reply-To: 35B4EC27.1E7B@lmtas.lmco.com

Scott Sheffield (sheffieldsy@lmtas.lmco.com) wrote:

: I have a function that I am trying to convert for use on my PC using
: adagide :

:   function "and" (l,r : in system.unsigned_word)
: 	return system.unsigned_word
: 	renames system."and";

If you want to 'and' two 16-bit values use the unsigned type defined
in the Interfaces package (unsigned_32, unsigned16, unsigned_8)
than the 'and' operator is predefined for you.

or define them yourself, like

	type Unsigned_Word is mod 2 ** 16;
	for Unsigned_Word'Size use 16;

and also have the and operator thrown in for free.

Jerry.

-- 
-- Jerry van Dijk  | email: jdijk@acm.org
-- Leiden, Holland | member Team-Ada
-- Ada & Win32: http://stad.dsl.nl/~jvandyk




      parent reply	other threads:[~1998-07-22  0:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1998-07-21  0:00 And Scott Sheffield
1998-07-22  0:00 ` And Anonymous
1998-07-22  0:00 ` Jerry van Dijk [this message]
replies disabled

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