diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2025-08-26 14:58:51 -0400 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2025-08-26 14:58:51 -0400 |
| commit | cb1d36c6d8bc84f3422c71ab3eb29606e80f7837 (patch) | |
| tree | 0c4c56effdcf258e9807f8d0257d6e445598b70f /src/parse/expressions.c | |
| parent | d25d5642392f93623d1eb4d11156d293fe6df546 (diff) | |
Formatting for reductions
Diffstat (limited to 'src/parse/expressions.c')
| -rw-r--r-- | src/parse/expressions.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/parse/expressions.c b/src/parse/expressions.c index 6104b2d2..32133fe9 100644 --- a/src/parse/expressions.c +++ b/src/parse/expressions.c @@ -49,7 +49,9 @@ ast_t *parse_reduction(parse_ctx_t *ctx, const char *pos) { ast_e op = match_binary_operator(&pos); if (op == Unknown) return NULL; - ast_t *key = NewAST(ctx->file, pos, pos, Var, .name = "$"); + const char *op_str = binop_operator(op); + assert(op_str); + ast_t *key = NewAST(ctx->file, pos, pos, Var, .name = op_str); for (bool progress = true; progress;) { ast_t *new_term; progress = |
