scc

Simple C99 Compiler
Log | Files | Refs | README | LICENSE

commit 9fdb7c764740da5a852bb02ec407c8b72da8db95
parent 0d0b0348c1e5864db9ccb539f98e49299833f68b
Author: Roberto E. Vargas Caballero <k0ga@shike2.com>
Date:   Wed, 16 Apr 2014 18:28:18 +0200

Update format of functions

This new format uses 'n' to allow pass a name to cc2

Diffstat:
code.c | 3++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/code.c b/code.c @@ -167,7 +167,8 @@ emitexp(Node *np) void emitfun(Symbol *sym) { - printf("X%s\n", sym->name); + printf("%c%d\tn%s\n", + sym->s.isglobal ? 'X' : 'Y', sym->id, sym->name); } void