Skip to content

Commit 3421566

Browse files
committed
patch 8.0.0124
Problem: Internal error for assert_inrange(1, 1). Solution: Adjust number of allowed arguments. (Dominique Pelle)
1 parent a899e6e commit 3421566

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

src/evalfunc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -471,7 +471,7 @@ static struct fst
471471
{"assert_exception", 1, 2, f_assert_exception},
472472
{"assert_fails", 1, 2, f_assert_fails},
473473
{"assert_false", 1, 2, f_assert_false},
474-
{"assert_inrange", 2, 3, f_assert_inrange},
474+
{"assert_inrange", 3, 4, f_assert_inrange},
475475
{"assert_match", 2, 3, f_assert_match},
476476
{"assert_notequal", 2, 3, f_assert_notequal},
477477
{"assert_notmatch", 2, 3, f_assert_notmatch},

src/testdir/test_assert.vim

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,8 @@ func Test_assert_inrange()
117117
call assert_inrange(5, 7, 8)
118118
call assert_match("Expected range 5 - 7, but got 8", v:errors[0])
119119
call remove(v:errors, 0)
120+
121+
call assert_fails('call assert_inrange(1, 1)', 'E119:')
120122
endfunc
121123

122124
func Test_user_is_happy()

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -764,6 +764,8 @@ static char *(features[]) =
764764

765765
static int included_patches[] =
766766
{ /* Add new patch number below this line */
767+
/**/
768+
124,
767769
/**/
768770
123,
769771
/**/

0 commit comments

Comments
 (0)