aboutsummaryrefslogtreecommitdiff
path: root/src/parse
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2025-08-31 23:33:22 -0400
committerBruce Hill <bruce@bruce-hill.com>2025-08-31 23:33:22 -0400
commit5fc7577b5a3bc2c445522dfd5b287e1c6eddc3e9 (patch)
tree34d44c9330dc3ec71fc850b95b3412a1ce292cb8 /src/parse
parenta571ccffd795a595e990a3405dcf977aafc33c6c (diff)
Switch to using optional return values for list indexing.
Diffstat (limited to 'src/parse')
-rw-r--r--src/parse/suffixes.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/parse/suffixes.c b/src/parse/suffixes.c
index 7e748caf..4aa09cb8 100644
--- a/src/parse/suffixes.c
+++ b/src/parse/suffixes.c
@@ -47,9 +47,8 @@ ast_t *parse_index_suffix(parse_ctx_t *ctx, ast_t *lhs) {
whitespace(&pos);
ast_t *index = optional(ctx, &pos, parse_extended_expr);
whitespace(&pos);
- bool unchecked = match(&pos, ";") && (spaces(&pos), match_word(&pos, "unchecked") != 0);
expect_closing(ctx, &pos, "]", "I wasn't able to parse the rest of this index");
- return NewAST(ctx->file, start, pos, Index, .indexed = lhs, .index = index, .unchecked = unchecked);
+ return NewAST(ctx->file, start, pos, Index, .indexed = lhs, .index = index);
}
ast_t *parse_comprehension_suffix(parse_ctx_t *ctx, ast_t *expr) {