scc

simple c99 compiler
git clone git://git.simple-cc.org/scc
Log | Files | Refs | Submodules | README | LICENSE

commit 7f67b52547e174f08e25f66932e29502be2c5074
parent 95bec877561deeb75c825e68850ec58d58c8ef8a
Author: Roberto E. Vargas Caballero <k0ga@shike2.com>
Date:   Fri, 20 May 2016 15:22:40 +0200

[cc1] Use ansi syntax for complex function pointer expressions

For a function pointer generated from a ternary operator is better
to use the ANSI syntax, because otherwise we have
too many parenthesis

Diffstat:
Mcc1/decl.c | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/cc1/decl.c b/cc1/decl.c @@ -290,7 +290,7 @@ fundcl(struct declarators *dp) type.prop = 0; k_r = (yytoken == ')' || yytoken == IDEN); - (*(k_r ? krfun : ansifun))(&type, types, syms, &ntypes, &nsyms); + (k_r ? krfun : ansifun)(&type, types, syms, &ntypes, &nsyms); expect(')'); type.n.elem = ntypes;