Module Name: src
Committed By: maya
Date: Sat Jan 5 09:16:46 UTC 2019
Modified Files:
src/include: stdlib.h
Log Message:
We can make a stronger guarantee than __pure.
abs/labs don't read global memory.
Make GCC 9 happier.
To generate a diff of this commit:
cvs rdiff -u -r1.120 -r1.121 src/include/stdlib.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/include/stdlib.h
diff -u src/include/stdlib.h:1.120 src/include/stdlib.h:1.121
--- src/include/stdlib.h:1.120 Wed Aug 15 10:21:42 2018
+++ src/include/stdlib.h Sat Jan 5 09:16:46 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: stdlib.h,v 1.120 2018/08/15 10:21:42 martin Exp $ */
+/* $NetBSD: stdlib.h,v 1.121 2019/01/05 09:16:46 maya Exp $ */
/*-
* Copyright (c) 1990, 1993
@@ -95,7 +95,7 @@ extern size_t __mb_cur_max;
__BEGIN_DECLS
__dead void _Exit(int);
__dead void abort(void);
-__pure int abs(int);
+__constfunc int abs(int);
int atexit(void (*)(void));
double atof(const char *);
int atoi(const char *);
@@ -111,7 +111,7 @@ div_t div(int, int);
__dead void exit(int);
void free(void *);
__aconst char *getenv(const char *);
-__pure long
+__constfunc long
labs(long);
ldiv_t ldiv(long, long);
void *malloc(size_t);