diff options
author | Joel Sherrill <joel.sherrill@oarcorp.com> | 2013-11-18 17:26:52 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@oarcorp.com> | 2013-11-18 17:26:52 +0000 |
commit | 8ab08406dadea2499a556446a0112b9a104cb1d3 (patch) | |
tree | 98164fd35a5f4de21bd0c4a23540d9f7aaf75408 /newlib/libc/include/stdlib.h | |
parent | 7c62befe16da50189ee807356b84822bdc5f42e6 (diff) | |
download | cygnal-8ab08406dadea2499a556446a0112b9a104cb1d3.tar.gz cygnal-8ab08406dadea2499a556446a0112b9a104cb1d3.tar.bz2 cygnal-8ab08406dadea2499a556446a0112b9a104cb1d3.zip |
2013-11-18 Sahil Patnayakuni <sahilp@oarcorp.com>
* libc/include/stdlib.h, libc/stdlib/mbstowcs.c,
libc/stdlib/mbstowcs_r.c, libc/stdlib/mbtowc.c,
libc/stdlib/mbtowc_r.c, libc/stdlib/strtod.c,
libc/stdlib/strtol.c, libc/stdlib/strtold.c,
libc/stdlib/strtoll.c, libc/stdlib/strtoll_r.c,
libc/stdlib/strtoul.c, libc/stdlib/strtoull.c,
libc/stdlib/strtoull_r.c, libc/stdlib/wcstombs.c,
libc/stdlib/wcstombs_r.c: Add restrict keyword.
Diffstat (limited to 'newlib/libc/include/stdlib.h')
-rw-r--r-- | newlib/libc/include/stdlib.h | 36 |
1 files changed, 18 insertions, 18 deletions
diff --git a/newlib/libc/include/stdlib.h b/newlib/libc/include/stdlib.h index fc15a3cce..4afc3f967 100644 --- a/newlib/libc/include/stdlib.h +++ b/newlib/libc/include/stdlib.h @@ -94,14 +94,14 @@ ldiv_t _EXFUN(ldiv,(long __numer, long __denom)); _PTR _EXFUN_NOTHROW(malloc,(size_t __size)); int _EXFUN(mblen,(const char *, size_t)); int _EXFUN(_mblen_r,(struct _reent *, const char *, size_t, _mbstate_t *)); -int _EXFUN(mbtowc,(wchar_t *, const char *, size_t)); -int _EXFUN(_mbtowc_r,(struct _reent *, wchar_t *, const char *, size_t, _mbstate_t *)); +int _EXFUN(mbtowc,(wchar_t *__restrict, const char *__restrict, size_t)); +int _EXFUN(_mbtowc_r,(struct _reent *, wchar_t *__restrict, const char *__restrict, size_t, _mbstate_t *)); int _EXFUN(wctomb,(char *, wchar_t)); int _EXFUN(_wctomb_r,(struct _reent *, char *, wchar_t, _mbstate_t *)); -size_t _EXFUN(mbstowcs,(wchar_t *, const char *, size_t)); -size_t _EXFUN(_mbstowcs_r,(struct _reent *, wchar_t *, const char *, size_t, _mbstate_t *)); -size_t _EXFUN(wcstombs,(char *, const wchar_t *, size_t)); -size_t _EXFUN(_wcstombs_r,(struct _reent *, char *, const wchar_t *, size_t, _mbstate_t *)); +size_t _EXFUN(mbstowcs,(wchar_t *__restrict, const char *__restrict, size_t)); +size_t _EXFUN(_mbstowcs_r,(struct _reent *, wchar_t *__restrict, const char *__restrict, size_t, _mbstate_t *)); +size_t _EXFUN(wcstombs,(char *__restrict, const wchar_t *__restrict, size_t)); +size_t _EXFUN(_wcstombs_r,(struct _reent *, char *__restrict, const wchar_t *__restrict, size_t, _mbstate_t *)); #ifndef __STRICT_ANSI__ #ifndef _REENT_ONLY char * _EXFUN(mkdtemp,(char *)); @@ -125,10 +125,10 @@ _PTR _EXFUN_NOTHROW(realloc,(_PTR __r, size_t __size)); _PTR _EXFUN(reallocf,(_PTR __r, size_t __size)); #endif _VOID _EXFUN(srand,(unsigned __seed)); -double _EXFUN(strtod,(const char *__n, char **__end_PTR)); -double _EXFUN(_strtod_r,(struct _reent *,const char *__n, char **__end_PTR)); +double _EXFUN(strtod,(const char *__restrict __n, char **__restrict __end_PTR)); +double _EXFUN(_strtod_r,(struct _reent *,const char *__restrict __n, char **__restrict __end_PTR)); #if !defined(__STRICT_ANSI__) || (__STDC_VERSION__ >= 199901L) || (__cplusplus >= 201103L) -float _EXFUN(strtof,(const char *__n, char **__end_PTR)); +float _EXFUN(strtof,(const char *__restrict __n, char **__restrict __end_PTR)); #endif #ifndef __STRICT_ANSI__ /* the following strtodf interface is deprecated...use strtof instead */ @@ -136,10 +136,10 @@ float _EXFUN(strtof,(const char *__n, char **__end_PTR)); # define strtodf strtof # endif #endif -long _EXFUN(strtol,(const char *__n, char **__end_PTR, int __base)); -long _EXFUN(_strtol_r,(struct _reent *,const char *__n, char **__end_PTR, int __base)); -unsigned long _EXFUN(strtoul,(const char *__n, char **__end_PTR, int __base)); -unsigned long _EXFUN(_strtoul_r,(struct _reent *,const char *__n, char **__end_PTR, int __base)); +long _EXFUN(strtol,(const char *__restrict __n, char **__restrict __end_PTR, int __base)); +long _EXFUN(_strtol_r,(struct _reent *,const char *__restrict __n, char **__restrict __end_PTR, int __base)); +unsigned long _EXFUN(strtoul,(const char *__restrict __n, char **__restrict __end_PTR, int __base)); +unsigned long _EXFUN(_strtoul_r,(struct _reent *,const char *__restrict __n, char **__restrict __end_PTR, int __base)); int _EXFUN(system,(const char *__string)); @@ -192,16 +192,16 @@ long long _EXFUN(llabs,(long long)); lldiv_t _EXFUN(lldiv,(long long __numer, long long __denom)); #endif /* ! __STRICT_ANSI__ */ #if !defined(__STRICT_ANSI__) || (__STDC_VERSION__ >= 199901L) || (__cplusplus >= 201103L) -long long _EXFUN(strtoll,(const char *__n, char **__end_PTR, int __base)); +long long _EXFUN(strtoll,(const char *__restrict __n, char **__restrict __end_PTR, int __base)); #endif #ifndef __STRICT_ANSI__ -long long _EXFUN(_strtoll_r,(struct _reent *, const char *__n, char **__end_PTR, int __base)); +long long _EXFUN(_strtoll_r,(struct _reent *, const char *__restrict __n, char **__restrict __end_PTR, int __base)); #endif /* ! __STRICT_ANSI__ */ #if !defined(__STRICT_ANSI__) || (__STDC_VERSION__ >= 199901L) || (__cplusplus >= 201103L) -unsigned long long _EXFUN(strtoull,(const char *__n, char **__end_PTR, int __base)); +unsigned long long _EXFUN(strtoull,(const char *__restrict __n, char **__restrict __end_PTR, int __base)); #endif #ifndef __STRICT_ANSI__ -unsigned long long _EXFUN(_strtoull_r,(struct _reent *, const char *__n, char **__end_PTR, int __base)); +unsigned long long _EXFUN(_strtoull_r,(struct _reent *, const char *__restrict __n, char **__restrict __end_PTR, int __base)); #ifndef __CYGWIN__ _VOID _EXFUN(cfree,(_PTR)); @@ -230,7 +230,7 @@ _VOID _EXFUN(__eprintf,(const char *, const char *, unsigned int, const char *)) /* On platforms where long double equals double. */ #ifdef _LDBL_EQ_DBL #if !defined(__STRICT_ANSI__) || (__STDC_VERSION__ >= 199901L) || (__cplusplus >= 201103L) -extern long double strtold (const char *, char **); +extern long double strtold (const char *__restrict, char **__restrict); #endif extern long double wcstold (const wchar_t *, wchar_t **); #endif /* _LDBL_EQ_DBL */ |