Skip to content

Commit 97496e7

Browse files
committed
FIX: error throwing an error on empty input must be only when used /next or /one refinements
related to: Oldes/Rebol-issues#2511
1 parent f7e0947 commit 97496e7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/core/l-scan.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -1931,7 +1931,7 @@ extern REBSER *Scan_Full_Block(SCAN_STATE *scan_state, REBYTE mode_char);
19311931
blk = Scan_Code(&scan_state, 0);
19321932
DS_RELOAD(ds); // in case stack moved
19331933

1934-
if (IS_END((REBVAL*)BLK_SKIP(blk, 0))) {
1934+
if (next && IS_END((REBVAL*)BLK_SKIP(blk, 0))) {
19351935
if (relax) {
19361936
ser = Make_Error(RE_PAST_END, src, 0, 0);
19371937
SET_ERROR(D_RET, RE_PAST_END, ser);

0 commit comments

Comments
 (0)