You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
A character or byte literal is not accepted as a match pattern ("expected pattern") #1295
Found rewriting `examples/json-parser` under #1150 ruling 4 (its tokenizer matches the next byte).
§22 (Lexical) says character and byte literals are integer literal values (`'a'`, `b'X'`), and integer literals are patterns (§9.7). The parser rejects both in pattern position:
Also inside a constructor pattern (`Some(b'{') => ...`). Both literals work in expressions (`ch == b'{'`, `ch in [b' ', b'\t']`). Expected: a char/byte literal pattern matches the integer value, exactly like `123 => ...`. Installed `with v0.15.2.1-g478b26481`.
The example spells the arms as guards (`Some(ch) if ch == b'{' =>`) until this lands.
Activity
examples: rewritten to the current spec (D55 ruling 4) + examples-tes…
examples: restore the spec spellings #1308 parked behind now-fixed co…