Importing inttypes methods from FreeBSD

Aditya Upadhyay aadit0402@gmail.com
Wed Jul 19 17:00:00 GMT 2017


I am attaching the patch for inttypes methods after modification. I am
requesting you to please review the same.

Regards,
Aditya

On Wed, Jul 19, 2017 at 9:14 PM, Corinna Vinschen <vinschen@redhat.com> wrote:
> On Jul 19 10:13, Craig Howland wrote:
>> On 07/19/2017 08:28 AM, Corinna Vinschen wrote:
>> > What you really want is to define a static function which takes the
>> > reent pointer and strtoimax_l/strtoimax only calling that, like this:
>> >
>> > --- snip ---
>> > static intmax_t
>> > _strtoimax_r(struct _reent *rptr, const char * __restrict nptr,
>> >          char ** __restrict endptr, int base, locale_t loc)
>> Corinna:
>>      Why static?  In general, the reentrant forms are included in the header
>> files so that they can be called directly if an application so desires.
>
> Good point.  Yes, the function should better be non-static and added
> to inttypes.h as well (unconditionally).
>
>
> Corinna
>
> --
> Corinna Vinschen
> Cygwin Maintainer
> Red Hat
-------------- next part --------------
A non-text attachment was scrubbed...
Name: v2-0001-Importing-imaxabs-inttype-methods-from-FreeBSD.patch
Type: text/x-patch
Size: 2515 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/newlib/attachments/20170719/1b152964/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: v2-0002-Importing-imaxdiv-inttype-method-from-FreeBSD.patch
Type: text/x-patch
Size: 2827 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/newlib/attachments/20170719/1b152964/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: v2-0003-Importing-strtoimax-inttype-method-from-FreeBSD.patch
Type: text/x-patch
Size: 5825 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/newlib/attachments/20170719/1b152964/attachment-0002.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: v2-0004-Importing-strtoimax-inttype-method-from-FreeBSD.patch
Type: text/x-patch
Size: 1789 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/newlib/attachments/20170719/1b152964/attachment-0003.bin>


More information about the Newlib mailing list