From 24abaf6a25fb8449a918ad8caa626da835e95521 Mon Sep 17 00:00:00 2001 From: George Koehler Date: Mon, 18 Dec 2017 20:39:56 -0500 Subject: [PATCH] Enable conditional expressions in splitting coercions. ncgg has parsed the optional conditional expression (optexpr) of each splitting coercion since commit 72b83cc in 1985; but for almost 33 years, ncg has ignored the expression in c2_expr. Few tables had conditional coercions (I only found them in arm and m68020), and no tables had conditional splitting coercions, so this only becomes a problem now as I try to add a conditional splitting coercion to powerpc. --- mach/proto/ncg/subr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mach/proto/ncg/subr.c b/mach/proto/ncg/subr.c index 0feb54f30..0dc045973 100644 --- a/mach/proto/ncg/subr.c +++ b/mach/proto/ncg/subr.c @@ -518,7 +518,7 @@ int split(token_p tp, int *ip, int ply, int toplevel) { int tpl; for (cp=c2coercs;cp->c2_texpno>=0; cp++) { - if (!match(tp,&machsets[cp->c2_texpno],0)) + if (!match(tp,&machsets[cp->c2_texpno],cp->c2_expr)) continue; ok=1; for (i=0; ok && ic2_nsplit;i++) {