Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.std.c > #6414

bit-precise bit-fields

Path csiph.com!weretis.net!feeder8.news.weretis.net!reader5.news.weretis.net!news.solani.org!.POSTED!not-for-mail
From Philipp Klaus Krause <pkk@spth.de>
Newsgroups comp.std.c
Subject bit-precise bit-fields
Date Tue, 4 Jan 2022 13:15:54 +0100
Message-ID <sr1dpq$bch$1@solani.org> (permalink)
Mime-Version 1.0
Content-Type text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding 7bit
Injection-Date Tue, 4 Jan 2022 12:15:54 -0000 (UTC)
Injection-Info solani.org; logging-data="11665"; mail-complaints-to="abuse@news.solani.org"
User-Agent Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.4.0
Cancel-Lock sha1:kvkqStURYCsb15vWKCxz5d4qTbA=
Content-Language en-US
X-User-ID eJwFwYEBwCAIA7CXYKVUz1GQ/09YQqRnKZIZHA4GeUR5Fdjmc+WYbhw9fWtrWyw3bPW1t/gDE2cQfA==
Xref csiph.com comp.std.c:6414

Show key headers only | View raw


C23 Bit-precise integer types 
(http://www.open-std.org/jtc1/sc22/wg14/www/docs/n2763.pdf) allow 
programmers to explicitly state their intent on how many bits are 
needed; but since they are addressable, they need padding bits when 
their width is not a multiple of CHAR_WIDTH. Some implementations might 
use more padding for alignment. Where there is a need to save memory, 
they are thus not suitable. Using bit-precise integer types in 
bit-fields solves this issue.

So, I'd like to see bit-fields of bit-precise integer types in C:

http://www.colecovision.eu/stuff/proposal-bit-precise-bit-fields.html

Back to comp.std.c | Previous | NextNext in thread | Find similar | Unroll thread


Thread

bit-precise bit-fields Philipp Klaus Krause <pkk@spth.de> - 2022-01-04 13:15 +0100
  Re: bit-precise bit-fields Tim Rentsch <tr.17687@z991.linuxsc.com> - 2022-01-17 09:51 -0800
    Re: bit-precise bit-fields David Brown <david.brown@hesbynett.no> - 2022-01-17 20:03 +0100

csiph-web