This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH][BZ 17979][BZ 17721] Fix issues with sys/cdefs.h and uchar.h when using non-gcc compiler.
- From: Dwight Guth <dwight dot guth at runtimeverification dot com>
- To: Joseph Myers <joseph at codesourcery dot com>
- Cc: Dwight Guth <dwight dot guth at runtimeverification dot com>, libc-alpha at sourceware dot org
- Date: Thu, 28 Jan 2016 17:47:10 -0600
- Subject: Re: [PATCH][BZ 17979][BZ 17721] Fix issues with sys/cdefs.h and uchar.h when using non-gcc compiler.
- Authentication-results: sourceware.org; auth=none
- References: <27c31890079f41775175b94a4abedb0c dot squirrel at server316 dot webhostingpad dot com> <alpine dot DEB dot 2 dot 10 dot 1601282115100 dot 6102 at digraph dot polyomino dot org dot uk> <CACLXh_1_dQ5D1QrKQN0pVPzt001WmS4BgwcKZkULK8XnbEMb+g at mail dot gmail dot com> <alpine dot DEB dot 2 dot 10 dot 1601282246340 dot 6102 at digraph dot polyomino dot org dot uk> <CACLXh_3rAudocTEbtZQpVoDcWgm_ww3KcX6j9XCkSRTZVPTUMg at mail dot gmail dot com> <alpine dot DEB dot 2 dot 10 dot 1601282251350 dot 6102 at digraph dot polyomino dot org dot uk> <20160128225845 dot GE14840 at vapier dot lan> <CACLXh_2711o7YKAXZXU2-OGvhcN0Z1TrBoiqi7PK9GpR_sR_mQ at mail dot gmail dot com> <alpine dot DEB dot 2 dot 10 dot 1601282316440 dot 6102 at digraph dot polyomino dot org dot uk> <CACLXh_2ouWg0y0jPK-MOeDMx1s8FSsRBuB+yxZpFocpEF2=+RQ at mail dot gmail dot com> <alpine dot DEB dot 2 dot 10 dot 1601282330200 dot 6102 at digraph dot polyomino dot org dot uk>
Would you see it as better to move stdint.h out of sysdeps, or to do
something similar to what's done with mbstate_t, NULL, size_t, etc by
defining a __need_uint_least16_t and __need_uint_least32_t and having
stdint.h define only a __uint_least16_t and __uint_least32_t type and
then exit, allowing those types to be used across an abstraction
boundary by uchar.h?
On Thu, Jan 28, 2016 at 5:33 PM, Joseph Myers <joseph@codesourcery.com> wrote:
> On Thu, 28 Jan 2016, Dwight Guth wrote:
>
>> Yes, that's reasonable. What would you see as the correct resolution
>> to the issue?
>
> I think defining to restrict based on __STDC_VERSION__ is reasonable
> (outside of the release freeze period).
>
> uchar.h is trickier in that stdint.h is theoretically system-specific
> (it's in sysdeps), so there's an abstraction violation in copying its
> types into uchar.h (not in sysdeps). I'd be happy for stdint.h and
> inttypes.h to move out of sysdeps, but any hardcoding should probably
> still be accompanied at least by a comment in stdint.h about where else
> the type information is embedded.
>
> --
> Joseph S. Myers
> joseph@codesourcery.com