This is the mail archive of the
mailing list for the newlib project.
Re: Patch - Add C99 restrict to iconv.h
- From: Joel Sherrill <joel dot sherrill at oarcorp dot com>
- To: newlib at sourceware dot org
- Date: Wed, 20 Nov 2013 07:40:19 -0600
- Subject: Re: Patch - Add C99 restrict to iconv.h
- Authentication-results: sourceware.org; auth=none
- References: <528C0A79 dot 8090607 at oarcorp dot com> <20131120095536 dot GD19426 at calimero dot vinschen dot de>
On 11/20/2013 3:55 AM, Corinna Vinschen wrote:
> On Nov 19 19:03, Joel Sherrill wrote:
>> This is the first restrict patch via Google Code-In.
>> It is another in the series to add the __restrict keyword.
>> Is this OK to commit?
> Basically, yes, just...
>> 2013-11-19 Daniel Ramirez <...>
>> * libc/iconv/lib/iconv.c, libc/include/iconv.h,
>> libc/sys/linux/iconv/iconv.c: Add restrict keyword. [...] Index:
RCS file: /cvs/src/src/newlib/libc/include/iconv.h,v
>> retrieving revision 1.3 diff -u -r1.3 iconv.h ---
>> newlib/libc/include/iconv.h 21 Aug 2009 20:27:10 -0000 1.3 +++
>> newlib/libc/include/iconv.h 20 Nov 2013 00:12:38 -0000 @@ -41,7
>> +41,10 @@ _EXFUN(iconv_open, (_CONST char *, _CONST char *)); ou
>> size_t -_EXFUN(iconv, (iconv_t, char **, size_t *, char **,
>> size_t *)); +_EXFUN(iconv, (iconv_t, char **__restrict, +
>> size_t *__restrict, + char **__restrict, +
>> size_t *__restrict));
> ...this could be a bit more compact:
> _EXFUN(iconv, (iconv_t, char **__restrict, size_t *__restrict, char
> **__restrict, size_t *__restrict));
Fixed. The first version was over 80 columns and this is what
happened. I have committed the more compact version.
Our instructions for adding __restrict to students is here:
If anyone has any suggestions to improve these, please
feel free to speak up. Google Code-In is a great way
to get repetitive tasks done as long as they can be
broken into small chunk, explained and are within
the technical grasp of the participants. FWIW this
year's participants have surprised us by blowing
through the "install a development environment
and run RTEMS hello world on gdb simulator" :)
> Thanks, Corinna
Joel Sherrill, Ph.D. Director of Research & Development
joel.sherrill@OARcorp.com On-Line Applications Research
Ask me about RTEMS: a free RTOS Huntsville AL 35805
Support Available (256) 722-9985