From ddce3738b1cfd4f54efd2b01bf4d3971929d1669 Mon Sep 17 00:00:00 2001 From: Krasimir Angelov Date: Tue, 18 Nov 2025 09:27:10 +0100 Subject: [PATCH] fix how probabilities are computed --- src/runtime/c/pgf/parser.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/runtime/c/pgf/parser.cxx b/src/runtime/c/pgf/parser.cxx index f1383f5a3..45f9c78b9 100644 --- a/src/runtime/c/pgf/parser.cxx +++ b/src/runtime/c/pgf/parser.cxx @@ -1009,7 +1009,7 @@ PgfExpr PgfParser::process_expr(ExprState *estate, prob_t *prob) for (ExprState *parent : estate->res->pending) { ExprState *app_state = new(parent->n_args) ExprState; app_state->expr = parent->expr ? u->eapp(parent->expr, estate->expr) : estate->expr; - app_state->prob = parent->prob+estate->prob; + app_state->prob = parent->prob+prob; app_state->hash = parent->hash * 31 + estate->hash; app_state->res = parent->res; app_state->index = parent->index+1;