summaryrefslogtreecommitdiff
path: root/top/maint.mk
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2016-04-13 00:06:36 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2016-04-13 00:13:23 -0700
commita4910b9481a9ce515cd5971c343efa4c1d046ef7 (patch)
tree1d55d0289c5054e07d836aa96ac054048d110979 /top/maint.mk
parent705764b377ebeef7bdba1a87fafd99cd56b6f3c9 (diff)
downloadgnulib-a4910b9481a9ce515cd5971c343efa4c1d046ef7.tar.gz
intprops, mktime, strtol: assume two's complement
These macros were not portable to every conforming C11 ones' complement platform. It's not worth the hassle of porting to some platforms that use ones' complement or signed magnitude, as such platforms are almost purely theoretical nowadays and porting even to some of them makes the code harder to review for little practical benefit. Problem reported by Florian Weimer in: https://sourceware.org/ml/libc-alpha/2016-04/msg00295.html * lib/intprops.h (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT) (TYPE_SIGNED_MAGNITUDE, _GL_INT_TWOS_COMPLEMENT): * lib/mktime.c (TYPE_TWOS_COMPLEMENT): * lib/strtol.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT) (TYPE_SIGNED_MAGNITUDE): Remove. All uses rewritten to assume two's complement, which is all we can reasonably test nowadays anyway. * top/maint.mk (_intprops_names): Remove the removed macros.
Diffstat (limited to 'top/maint.mk')
-rw-r--r--top/maint.mk3
1 files changed, 1 insertions, 2 deletions
diff --git a/top/maint.mk b/top/maint.mk
index 947032879c..aa23364a1b 100644
--- a/top/maint.mk
+++ b/top/maint.mk
@@ -651,8 +651,7 @@ sc_prohibit_strings_without_use:
# Get the list of symbol names with this:
# perl -lne '/^# *define ([A-Z]\w+)\(/ and print $1' lib/intprops.h|fmt
_intprops_names = \
- TYPE_IS_INTEGER TYPE_TWOS_COMPLEMENT TYPE_ONES_COMPLEMENT \
- TYPE_SIGNED_MAGNITUDE TYPE_SIGNED TYPE_MINIMUM TYPE_MAXIMUM \
+ TYPE_IS_INTEGER TYPE_SIGNED TYPE_MINIMUM TYPE_MAXIMUM \
INT_BITS_STRLEN_BOUND INT_STRLEN_BOUND INT_BUFSIZE_BOUND \
INT_ADD_RANGE_OVERFLOW INT_SUBTRACT_RANGE_OVERFLOW \
INT_NEGATE_RANGE_OVERFLOW INT_MULTIPLY_RANGE_OVERFLOW \