Liste des Groupes | Revenir à c arch |
On Thu, 5 Sep 2024 11:36:22 -0000 (UTC)[snip]
Thomas Koenig <tkoenig@netcologne.de> wrote:
Michael S <already5chosen@yahoo.com> schrieb:On Wed, 4 Sep 2024 17:08:36 -0000 (UTC)
The Unsigned_nn names are defined in the library package Ada.Interfaces, so the names were chosen to match common usage in other languages and in HW-speak. The "_nn" is target-specific, no values are standardized, but of course most common HW has some powers-of-two values.In Ada Language manual they are called Modular types, which is not bad.BTW, do your unsigned integers have defined behavior in case of>
overflow? Is it defined as a modulo 2**size?
Yes.
>If the answers are yes, then may be you can find better name than>
'unsigned'?
It's the name that C uses, and what people are used to. It is a
bit out of my hand now, because the proposal has been accepted
by J3, but what other suggestions would you have?
Unfortunately, specific modular types defined in Ada's predefined
packages are named Unsigned_nn and Cardinal. Neither is a name I would
suggest.
Les messages affichés proviennent d'usenet.