diff options
author | Adrian Thurston <thurston@complang.org> | 2014-01-06 20:17:58 -0500 |
---|---|---|
committer | Adrian Thurston <thurston@complang.org> | 2014-01-06 20:17:58 -0500 |
commit | 4f9b5d9846e279ec546298ef99faf95cac21e183 (patch) | |
tree | de7d5507ed21f7f885e07c28a153a0e6307d0677 /src/parser.h | |
parent | 95a688ad149ab1c579d358daacd06d609b517dd6 (diff) | |
download | colm-4f9b5d9846e279ec546298ef99faf95cac21e183.tar.gz |
added wrapper function for current namespace
Diffstat (limited to 'src/parser.h')
-rw-r--r-- | src/parser.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/parser.h b/src/parser.h index a3829d55..37af7e7e 100644 --- a/src/parser.h +++ b/src/parser.h @@ -49,9 +49,13 @@ struct BaseParser bool insideRegion() { return regionStack.length() > 0; } + Context *curContext() { return contextStack.length() == 0 ? 0 : contextStack.top(); } + Namespace *curNspace() + { return namespaceStack.top(); } + /* Lexical feedback. */ void init(); |