diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2014-07-26 06:17:25 -0700 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2014-07-26 06:17:25 -0700 |
commit | 9e9f8582a893f1e97b1f8955f69b96f969ee1f85 (patch) | |
tree | ef8b4c36f8b88d1273572b8140a8651854b65e6b /src/data.c | |
parent | 54e3f15626296c1ece932852df2b3d4938b0b44a (diff) | |
download | emacs-9e9f8582a893f1e97b1f8955f69b96f969ee1f85.tar.gz |
Revert previous change.
There is certainly nothing wrong with writing code like 'lo <= i
&& i <= hi', even if LO happens to a constant. There isn't even
anything wrong in general with writing 'a <= b' if A happens to
be a constant. At any rate stylistic changes shouldn't
be done like this without discussion.
Diffstat (limited to 'src/data.c')
-rw-r--r-- | src/data.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/data.c b/src/data.c index cb0e9a825fb..3e651414e68 100644 --- a/src/data.c +++ b/src/data.c @@ -2460,13 +2460,13 @@ cons_to_unsigned (Lisp_Object c, uintmax_t max) uintmax_t val IF_LINT (= 0); if (INTEGERP (c)) { - valid = XINT (c) >= 0; + valid = 0 <= XINT (c); val = XINT (c); } else if (FLOATP (c)) { double d = XFLOAT_DATA (c); - if (d >= 0 + if (0 <= d && d < (max == UINTMAX_MAX ? (double) UINTMAX_MAX + 1 : max + 1)) { val = d; |