diff options
author | Joel Sherrill <joel.sherrill@oarcorp.com> | 2013-11-25 13:46:23 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@oarcorp.com> | 2013-11-25 13:46:23 +0000 |
commit | d482870337349732ad1c9f3715730fd32b6216d0 (patch) | |
tree | a7395d230c93fee8c52d2b4730963001bdf7149d /newlib/libc/include/time.h | |
parent | 3073f26d6ab5d0ce902d5bfe75600e6577d903c9 (diff) | |
download | cygnal-d482870337349732ad1c9f3715730fd32b6216d0.tar.gz cygnal-d482870337349732ad1c9f3715730fd32b6216d0.tar.bz2 cygnal-d482870337349732ad1c9f3715730fd32b6216d0.zip |
2013-11-25 Sahil Patnayakuni <sahil.patnayakuni@gmail.com>
* libc/include/time.h (time): Add restrict keyword.
* libc/include/wchar.h (wcsftime): Add restrict keyword.
* libc/time/asctime_r.c (asctime_r): Same.
* libc/time/gmtime_r.c (gmtime_r): Same.
* libc/time/lcltime_r.c (lcltime_r): Same.
* libc/time/strftime.c (strftime): Same.
* libc/time/strptime.c (strptime): Same.
* libc/sys/linux/linuxthreads/timer_create.c (timer_create): Same.
* libc/sys/linux/linuxthreads/timer_settime.c (timer_settime): Same.
Diffstat (limited to 'newlib/libc/include/time.h')
-rw-r--r-- | newlib/libc/include/time.h | 26 |
1 files changed, 18 insertions, 8 deletions
diff --git a/newlib/libc/include/time.h b/newlib/libc/include/time.h index c760297f9..b91b03920 100644 --- a/newlib/libc/include/time.h +++ b/newlib/libc/include/time.h @@ -51,12 +51,17 @@ char *_EXFUN(ctime, (const time_t *_time)); struct tm *_EXFUN(gmtime, (const time_t *_timer)); struct tm *_EXFUN(localtime,(const time_t *_timer)); #endif -size_t _EXFUN(strftime, (char *_s, size_t _maxsize, const char *_fmt, const struct tm *_t)); +size_t _EXFUN(strftime, (char *__restrict _s, + size_t _maxsize, const char *__restrict _fmt, + const struct tm *__restrict _t)); -char *_EXFUN(asctime_r, (const struct tm *, char *)); +char *_EXFUN(asctime_r, (const struct tm *__restrict, + char *__restrict)); char *_EXFUN(ctime_r, (const time_t *, char *)); -struct tm *_EXFUN(gmtime_r, (const time_t *, struct tm *)); -struct tm *_EXFUN(localtime_r, (const time_t *, struct tm *)); +struct tm *_EXFUN(gmtime_r, (const time_t *__restrict, + struct tm *__restrict)); +struct tm *_EXFUN(localtime_r, (const time_t *__restrict, + struct tm *__restrict)); _END_STD_C @@ -65,7 +70,9 @@ extern "C" { #endif #ifndef __STRICT_ANSI__ -char *_EXFUN(strptime, (const char *, const char *, struct tm *)); +char *_EXFUN(strptime, (const char *__restrict, + const char *__restrict, + struct tm *__restrict)); _VOID _EXFUN(tzset, (_VOID)); _VOID _EXFUN(_tzset_r, (struct _reent *)); @@ -150,7 +157,9 @@ int _EXFUN(clock_getres, (clockid_t clock_id, struct timespec *res)); /* Create a Per-Process Timer, P1003.1b-1993, p. 264 */ int _EXFUN(timer_create, - (clockid_t clock_id, struct sigevent *evp, timer_t *timerid)); + (clockid_t clock_id, + struct sigevent *__restrict evp, + timer_t *__restrict timerid)); /* Delete a Per_process Timer, P1003.1b-1993, p. 266 */ @@ -159,8 +168,9 @@ int _EXFUN(timer_delete, (timer_t timerid)); /* Per-Process Timers, P1003.1b-1993, p. 267 */ int _EXFUN(timer_settime, - (timer_t timerid, int flags, const struct itimerspec *value, - struct itimerspec *ovalue)); + (timer_t timerid, int flags, + const struct itimerspec *__restrict value, + struct itimerspec *__restrict ovalue)); int _EXFUN(timer_gettime, (timer_t timerid, struct itimerspec *value)); int _EXFUN(timer_getoverrun, (timer_t timerid)); |