From fdc05fd0bd5d0a5dc7b8cbafd93e0d0308b85299 Mon Sep 17 00:00:00 2001 From: Oldes Date: Wed, 27 Jun 2018 21:36:36 +0200 Subject: [PATCH] FIX: Bitset not allowed in to/thru block Allow to/thru [bitset|...] in PARSE For example: ``` >> x: charset "x" y: charset "y" parse "y" [thru [x | y]] == true ``` Fixes: https://github.com/rebol/rebol-issues/issues/2141 (cherry picked from commit 68a0e0af939e26b52f72e3cd3a64d9c838ff0e98) --- src/core/u-parse.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/core/u-parse.c b/src/core/u-parse.c index a4a017b63a..1728d13a74 100644 --- a/src/core/u-parse.c +++ b/src/core/u-parse.c @@ -435,6 +435,11 @@ void Print_Parse_Index(REBCNT type, REBVAL *rules, REBSER *series, REBCNT index) } } } + // bitset + else if (IS_BITSET(item)) { + if (Check_Bit(VAL_SERIES(item), ch1, !HAS_CASE(parse))) + goto found1; + } else if (ANY_STR(item)) { ch2 = VAL_ANY_CHAR(item); if (!HAS_CASE(parse)) ch2 = UP_CASE(ch2);