comp.lang.ada
 help / color / mirror / Atom feed
From: Brian Drummond <brian@shapes.demon.co.uk>
Subject: Re: Interfaces.Shift_Left
Date: Tue, 13 Dec 2011 12:00:15 +0000 (UTC)
Date: 2011-12-13T12:00:15+00:00	[thread overview]
Message-ID: <jc7eof$1fe$1@dont-email.me> (raw)
In-Reply-To: 18214312-82f5-45c4-b20d-cb530b500929@h3g2000yqa.googlegroups.com

On Mon, 12 Dec 2011 14:30:51 -0800, awdorrin wrote:

> Perhaps I'm just brain-dead after staring at code all day - but I'm
> currently stumped and hoping someone could point me in the right
> direction.
> 
> I've been trying to update old Ada code to Ada95 standards and wanted to
> replace the calls to a custom C 'bit' library with the methods available
> in the Interface package.
> 
> The interface package only takes unsigned values as parameters, which I
> figured is fine since at a bit level sign doesn't really matter, but
> looks like I was wrong, as I'm now encountering a constraint error after
> a Shift_Left operation's results are casted back to an Integer_32 type.

Is there any way you could use modular types instead? They are closer to 
the semantics of C unsigned.

- Brian



  parent reply	other threads:[~2011-12-13 12:00 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-12 22:30 Interfaces.Shift_Left awdorrin
2011-12-12 23:34 ` Interfaces.Shift_Left Simon Wright
2011-12-13  1:36   ` Interfaces.Shift_Left Adam Beneschan
2011-12-13 12:00 ` Brian Drummond [this message]
2011-12-13 13:15   ` Interfaces.Shift_Left awdorrin
2011-12-13 21:48     ` Interfaces.Shift_Left Randy Brukardt
2011-12-14 18:28       ` Interfaces.Shift_Left awdorrin
2011-12-14 22:49         ` Interfaces.Shift_Left Randy Brukardt
2011-12-15  9:51           ` Interfaces.Shift_Left Niklas Holsti
2011-12-16  0:23             ` Interfaces.Shift_Left Randy Brukardt
2011-12-18 20:47               ` Interfaces.Shift_Left Niklas Holsti
2011-12-20  0:38                 ` Interfaces.Shift_Left Randy Brukardt
2011-12-20  2:18                   ` Interfaces.Shift_Left Shark8
2011-12-20 10:08                   ` Interfaces.Shift_Left Dmitry A. Kazakov
2011-12-20 19:38                   ` Interfaces.Shift_Left Niklas Holsti
2011-12-20 20:46                     ` Interfaces.Shift_Left Niklas Holsti
2011-12-20 21:13                       ` Interfaces.Shift_Left Simon Wright
2011-12-20 21:08                     ` Interfaces.Shift_Left Simon Wright
2011-12-20 23:26                       ` Interfaces.Shift_Left Randy Brukardt
2011-12-20 23:36                     ` Interfaces.Shift_Left Randy Brukardt
2011-12-21  0:44                       ` Interfaces.Shift_Left Georg Bauhaus
2011-12-21  7:23                       ` Interfaces.Shift_Left AdaMagica
replies disabled

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