[PATCH 02/18] Provide POSIX defined id_t in <sys/types.h>

Corinna Vinschen vinschen@redhat.com
Fri Apr 15 09:40:00 GMT 2016


On Apr 15 11:34, Sebastian Huber wrote:
> On 15/04/16 11:29, Corinna Vinschen wrote:
> >On Apr 15 11:08, Sebastian Huber wrote:
> >>>With the defaults for
> >>>
> >>>#if defined(__XMK__)
> >>>typedef signed char __pid_t;
> >>>#else
> >>>typedef int __pid_t;
> >>>#endif
> >>>
> >>>#ifndef __machine_dev_t_defined
> >>>typedef short __dev_t;
> >>>#endif
> >>>
> >>>#ifndef __machine_uid_t_defined
> >>>typedef unsigned short __uid_t;
> >>>#endif
> >>>
> >>>#ifndef __machine_gid_t_defined
> >>>typedef unsigned short __gid_t;
> >>>#endif
> >>>
> >>>the use of __uint32_t is wrong for ILP64 targets (yes, very exotic).
> >...while the usage of __pid_t is potentially misleading and wrong for
> >__XMK__ (whatever that is).
> >
> >Do we support ILP64 targets?  If not, __uint32_t sounds like a good
> >compromise for now.
> 
> Ok, I will correct this in v2.

Thanks.

> >>>we should use fixed-size types in <sys/_types.h> throughout.
> >That would be helpful to clear up confusion.
> 
> We should not do too many things at once, so this should be done in a follow
> up patch set.

Definitely.  It's just something to keep in mind.


Thanks,
Corinna

-- 
Corinna Vinschen
Cygwin Maintainer
Red Hat
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/newlib/attachments/20160415/73a5a1df/attachment.sig>


More information about the Newlib mailing list