scc

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

commit 8a71476cce84016b86892eeae18341232a5f612c
parent da8a014ccd89acf7d31ea34af8016de61126a446
Author: Roberto E. Vargas Caballero <k0ga@shike2.com>
Date:   Mon, 24 Aug 2015 21:50:25 +0200

Make structs more similars to other declarations

Moving the trailing '(' to the next line makes that structs
follow the same rule that other types follow.

Diffstat:
Mcc1/code.c | 2+-
Mcc1/tests/test002.c | 3++-
2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/cc1/code.c b/cc1/code.c @@ -253,7 +253,7 @@ emittype(Type *tp) emitletter(tp); if ((tag = tp->tag->name) != NULL) printf("\t%s", tag); - puts("\t("); + puts("\n("); n = tp->n.elem; for (sp = tp->p.fields; n-- > 0; ++sp) emit(ODECL, *sp); diff --git a/cc1/tests/test002.c b/cc1/tests/test002.c @@ -7,7 +7,8 @@ F1 G6 F1 main { - -S2 S ( +S2 S +( M5 I i ) A2 S2 y