From f6f09cbc76c3e47aec23898e024ff5bb5f061bc4 Mon Sep 17 00:00:00 2001 From: Koichi Sasada Date: Mon, 15 Jul 2019 10:19:25 +0900 Subject: introduce RUBY_ASSERT_ALWAYS(expr). RUBY_ASSERT_ALWAYS(expr) ignores NDEBUG (we cannot remove this assertion). --- array.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'array.c') diff --git a/array.c b/array.c index 31f078610d..c693b00755 100644 --- a/array.c +++ b/array.c @@ -1125,7 +1125,7 @@ ary_take_first_or_last(int argc, const VALUE *argv, VALUE ary, enum ary_take_pos /* the case optional argument is omitted should be handled in * callers of this function. if another arity case is added, * this arity check needs to rewrite. */ - RUBY_ASSERT_WHEN(TRUE, argc == 1); + RUBY_ASSERT_ALWAYS(argc == 1); n = NUM2LONG(argv[0]); len = RARRAY_LEN(ary); -- cgit v1.2.3