summaryrefslogtreecommitdiff
path: root/tools/d2c/syntax.c
diff options
context:
space:
mode:
authorCyrille Bagard <nocbos@gmail.com>2018-04-02 14:43:47 (GMT)
committerCyrille Bagard <nocbos@gmail.com>2018-04-02 14:43:47 (GMT)
commitf9404bf68a067b06986cd85855c43795ec578dbd (patch)
tree57f481aced2c69ddf6ac9766f310be86ebe03f6f /tools/d2c/syntax.c
parentd69503d7aeceddc52dfee9481e6a0e8ba9c1fc85 (diff)
Removed lots of uninitialized uses, mostly in NDEBUG mode.
Diffstat (limited to 'tools/d2c/syntax.c')
-rw-r--r--tools/d2c/syntax.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/d2c/syntax.c b/tools/d2c/syntax.c
index c0842a7..de1d693 100644
--- a/tools/d2c/syntax.c
+++ b/tools/d2c/syntax.c
@@ -284,6 +284,12 @@ bool write_encoding_syntax(const encoding_syntax *syntax, int fd, const char *ar
}
+ if (!alone)
+ {
+ dprintf(fd, "\t%sassert(result == NULL);\n", tab);
+ dprintf(fd, "\n");
+ }
+
dprintf(fd, "\t%sresult = g_%s_instruction_new(\"%s\");\n",
tab, arch, get_keyword_from_asm_pattern(syntax->pattern));