[hackers] [scc] [cc1] Add debug information to pushctx() and popctx() || Roberto E. Vargas Caballero
commit 3261788e3d8b7782ff0ade7b391572c54485e644
Author: Roberto E. Vargas Caballero <k0ga_AT_shike2.com>
AuthorDate: Fri Feb 24 06:03:36 2017 +0100
Commit: Roberto E. Vargas Caballero <k0ga_AT_shike2.com>
CommitDate: Fri Feb 24 19:55:49 2017 +0100
[cc1] Add debug information to pushctx() and popctx()
This debug information is useful to understand how
the context stack is evoluting in the time.
diff --git a/cc1/symbol.c b/cc1/symbol.c
index 7cb8d6f..3d17c2b 100644
--- a/cc1/symbol.c
+++ b/cc1/symbol.c
_AT_@ -97,6 +97,7 @@ unlinkhash(Symbol *sym)
void
pushctx(void)
{
+ DBG("SYM: pushed context %d", curctx+1);
if (++curctx == NR_BLOCK+1)
error("too many nested blocks");
}
_AT_@ -131,6 +132,7 @@ popctx(void)
Symbol *next, *sym;
int ns, dangling = 0;
+ DBG("SYM: poped context %d", curctx);
/*
* we have to be careful before popping the current
* context, because since the parser is one token
Received on Fri Feb 24 2017 - 19:56:14 CET
This archive was generated by hypermail 2.3.0
: Fri Feb 24 2017 - 20:00:19 CET