From: Pan Li Date: Sat, 25 May 2024 15:16:50 +0000 (+0800) Subject: Gen-Match: Fix gen_kids_1 right hand braces mis-alignment X-Git-Tag: basepoints/gcc-16~8713 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5d99cf74c9f748c93ea218eca9bd2f08edfb2a88;p=thirdparty%2Fgcc.git Gen-Match: Fix gen_kids_1 right hand braces mis-alignment Notice some mis-alignment for gen_kids_1 right hand braces as below: if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (... { if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (... { { tree captures[2] ATTRIBUTE_UNUSED = {... { res_ops[0] = captures[0]; res_ops[1] = captures[1]; if (UNLIKELY (debug_dump)) ... return true; } } } } } // mis-aligned here. } The below test are passed for this patch: * The x86 bootstrap test. * The x86 fully regression test. gcc/ChangeLog: * genmatch.cc (dt_node::gen_kids_1): Fix indenet mis-aligned. Signed-off-by: Pan Li --- diff --git a/gcc/genmatch.cc b/gcc/genmatch.cc index c982c95b70f..f1e0e7abe0c 100644 --- a/gcc/genmatch.cc +++ b/gcc/genmatch.cc @@ -3428,7 +3428,7 @@ dt_node::gen_kids_1 (FILE *f, int indent, bool gimple, int depth, child_opname, kid_opname, j); } preds[i]->gen_kids (f, indent + 4, gimple, depth); - fprintf (f, "}\n"); + fprintf_indent (f, indent, " }\n"); indent -= 2; fprintf_indent (f, indent, "}\n"); }