Sebastian's Patches Committed
Sebastian Huber
sebastian.huber@embedded-brains.de
Sat Oct 26 13:44:00 GMT 2013
On 10/25/2013 11:20 PM, Hans-Peter Nilsson wrote:
>> From: Hans-Peter Nilsson<hp@axis.com>
>> >Date: Fri, 25 Oct 2013 21:19:02 +0200
>> >Maybe make use of those __INT<X>_TYPE__-like macros defined in
>> >recent gcc when defining the __int<x>_t-line macros in
>> >_default_types.h. Perhaps it's even ok to just do that and, as
>> >a fallback only, cheat and include stdint.h, if
>> >e.g. __UINT32_TYPE__ isn't defined.;)
> No task being too simple, here's a patch to do that. It also
> doesn't define __*int_least*_t types for those optional types
> unless they're provided, fixing a further buglet when including
> stdint.h which would make a difference only if it's actually
> possible to use a non-newlib-stdint.h from within newlib. A gcc
> build of cris-elf succeeds and has passed the earlier gcc
> test-suite point of failure. Assuming no regressions, is this
> ok to check in?
>
> Or would you prefer the other way, putting the corresponding
> part of libc/include/stdint.h here and making
> libc/include/stdint.h include <machine/_default_types.h>?
Yes, I would move the type definitions currently done in Newlib
<stdint.h> to
<machine/_default_types.h> and simply use
typedef __XXX_t XXX_t;
in <stdint.h>. The new <machine/_default_types.h> should also use GCCs
built-in defines for the standard types.
This helps to clean up <sys/cdefs.h> as well, since it includes
currently also <stdint.h>.
--
Sebastian Huber, embedded brains GmbH
Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone : +49 89 189 47 41-16
Fax : +49 89 189 47 41-09
E-Mail : sebastian.huber@embedded-brains.de
PGP : Public key available on request.
Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.
More information about the Newlib
mailing list