[Bug c/83294] int32_t & related definitions wrong with -funsigned-bitfields

2024-10-13 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83294 Andrew Pinski changed: What|Removed |Added CC||luigighiron at gmail dot com --- Comment

[Bug c/83294] int32_t & related definitions wrong with -funsigned-bitfields

2024-07-31 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83294 Andrew Pinski changed: What|Removed |Added CC||mital at mitalashok dot co.uk --- Commen

[Bug c/83294] int32_t & related definitions wrong with -funsigned-bitfields

2024-03-12 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83294 --- Comment #9 from Andrew Pinski --- https://inbox.sourceware.org/gcc-patches/7a5ec7af-fdbf-470f-9414-bf4110331...@ventanamicro.com/

[Bug c/83294] int32_t & related definitions wrong with -funsigned-bitfields

2018-03-12 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83294 --- Comment #8 from Jonathan Wakely --- FWIW C++ Core DR 739 is a DR against C++11 and C++98, so should be considered to apply pre-C++14 too. http://www.open-std.org/jtc1/sc22/wg21/docs/cwg_defects.html#739 This has no bearing on the C behaviou

[Bug c/83294] int32_t & related definitions wrong with -funsigned-bitfields

2018-03-12 Thread bugdal at aerifal dot cx
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83294 --- Comment #7 from Rich Felker --- Thanks. I think between footnote 125 and DR#315 the intent is clear and this bug report stands as written.

[Bug c/83294] int32_t & related definitions wrong with -funsigned-bitfields

2018-03-12 Thread joseph at codesourcery dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83294 --- Comment #6 from joseph at codesourcery dot com --- The response to C99 DR#315 says that for all the types not specifying "signed" or "unsigned" explicitly, if an implementation accepts them as bit-field types it's implementation-defined wha

[Bug c/83294] int32_t & related definitions wrong with -funsigned-bitfields

2018-03-10 Thread bugdal at aerifal dot cx
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83294 --- Comment #5 from Rich Felker --- Reading the relevant part of the standard in more detail, it seems like it's a GCC bug that GCC is applying the exception for plain int to typedefs. ΒΆ5: "Each of the comma-separated multisets designates the sa

[Bug c/83294] int32_t & related definitions wrong with -funsigned-bitfields

2018-03-10 Thread bugdal at aerifal dot cx
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83294 --- Comment #4 from Rich Felker --- Further examination shows that this GCC feature (-funsigned-bitfields) is actually buggy/non-conforming. It changes the default signedness of all integer types in bitfields, not just plain int. This behavior se

[Bug c/83294] int32_t & related definitions wrong with -funsigned-bitfields

2017-12-05 Thread joseph at codesourcery dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83294 --- Comment #3 from joseph at codesourcery dot com --- FWIW, current glibc already uses signed int for int32_t (via using it for __int32_t which is used to define int32_t), entirely as an accident following a header refactoring, but not for oth

[Bug c/83294] int32_t & related definitions wrong with -funsigned-bitfields

2017-12-05 Thread bugdal at aerifal dot cx
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83294 --- Comment #2 from Rich Felker --- I agree it's not clear if there's a conformance distinction or just a QoI issue, but it seems really unfortunate for int32_t not to be usable in bitfields if -funsigned-bitfields might be passed to GCC, since t

[Bug c/83294] int32_t & related definitions wrong with -funsigned-bitfields

2017-12-05 Thread joseph at codesourcery dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83294 --- Comment #1 from joseph at codesourcery dot com --- I'm not aware of a standard requirement not to use plain int for int32_t (even with unsigned bit-fields), though it may well be useful to make the signedness explicit. After all, int is a