summaryrefslogtreecommitdiff
path: root/handy.h
diff options
context:
space:
mode:
authorKarl Williamson <khw@cpan.org>2019-09-21 12:23:49 -0600
committerKarl Williamson <khw@cpan.org>2019-09-25 22:30:43 -0600
commit1eaefa6ebf606d54de28b69d64510e8179c754ef (patch)
tree7dbc675ba7328a43f38645134903149f802c204a /handy.h
parent45f4bb73962fcf38d8ded9b6067d2c73ff03a0ed (diff)
downloadperl-1eaefa6ebf606d54de28b69d64510e8179c754ef.tar.gz
handy.h: Rmv duplicated assert in inRANGE()
This assertion is done in the macro that is called to do the real work.
Diffstat (limited to 'handy.h')
-rw-r--r--handy.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/handy.h b/handy.h
index f011882af6..e584efd218 100644
--- a/handy.h
+++ b/handy.h
@@ -1326,7 +1326,7 @@ or casts
/* Returns true if c is in the range l..u, where 'l' is non-negative
* Written this way so that after optimization, only one conditional test is
* needed. */
-#define inRANGE(c, l, u) (__ASSERT_((l) >= 0) __ASSERT_((u) >= (l)) \
+#define inRANGE(c, l, u) (__ASSERT_((u) >= (l)) \
( (sizeof(c) == sizeof(U8)) ? withinCOUNT(((U8) (c)), (l), ((u) - (l))) \
: (sizeof(c) == sizeof(U16)) ? withinCOUNT(((U16) (c)), (l), ((u) - (l))) \
: (sizeof(c) == sizeof(U32)) ? withinCOUNT(((U32) (c)), (l), ((u) - (l))) \