> -----Original Message-----
> From: IBM Mainframe Discussion List [mailto:[email protected]] On
> Behalf Of Shmuel Metz (Seymour J.)
> Sent: Thursday, November 20, 2014 10:36 AM
> To: [email protected]
> Subject: Re: How declare in C++ a constant in an assembler module?

<snip>
 
> But I'd like to know how, in C, I can specify the size of an integer
> in bits, so that I get the proper allocation when I am on a 12-bit, an
> 18-bit, a 24-bit, a 30-bit, a 36-bit, a 48-bit, a 60-bit or a 64-bit
> machine.

The standard provides optional types for 8, 16, 32, and 64.  In the general
case, the only way I know is to use a bit-field within a structure.  With
judicious use of placeholder bit-fields, you can even specify which set of
bits within the bytes you want the integer to occupy.

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to