nushell/crates/nu-parser/tests
zc he 3836da0cf1
fix(parser): mixed side effects of different choices in parse_oneof (#14912)
# Description

This PR fixes #14784.

<img width="384" alt="image"
src="https://github.com/user-attachments/assets/aac063a0-645d-4adb-a399-525bdb004999"
/>

Also fixes the related behavior of lsp:

completion won't work in match/else blocks, because:

1. truncation in completion causes unmatched `{`, thus a parse error.
2. the parse error further leads to a state where the whole block
expression marked as garbage

<img width="453" alt="image"
src="https://github.com/user-attachments/assets/aaf86ccc-646e-4b91-bb27-4b1737100ff2"
/>

Related PR: #14856, @tmillr

I don't have any background knowledge of those `propagate_error`,
@sgvictorino you may want to review this.

# User-Facing Changes

# Tests + Formatting

# After Submitting
2025-01-30 06:30:45 -06:00
..
test_lex.rs 14523 all comments should be prefixed with space tab or be beginning of token (#14616) 2024-12-25 21:31:51 +08:00
test_parser_unicode_escapes.rs IO and redirection overhaul (#11934) 2024-03-14 15:51:55 -05:00
test_parser.rs fix(parser): mixed side effects of different choices in parse_oneof (#14912) 2025-01-30 06:30:45 -06:00