projects
/
cparser
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
df3615a
)
only output digits in integer literals in write_jna
author
Matthias Braun
<matthias.braun@kit.edu>
Thu, 26 Jul 2012 14:13:02 +0000
(16:13 +0200)
committer
Matthias Braun
<matthias.braun@kit.edu>
Thu, 26 Jul 2012 14:34:12 +0000
(16:34 +0200)
wrappergen/write_jna.c
patch
|
blob
|
history
diff --git
a/wrappergen/write_jna.c
b/wrappergen/write_jna.c
index
b209042
..
9814b8f
100644
(file)
--- a/
wrappergen/write_jna.c
+++ b/
wrappergen/write_jna.c
@@
-308,7
+308,10
@@
static void write_expression(const expression_t *expression)
/* TODO */
switch(expression->kind) {
case EXPR_LITERAL_INTEGER:
- fprintf(out, "%s", expression->literal.value.begin);
+ for (const char *c = expression->literal.value.begin;
+ (*c >= '0' && *c <= '9') || *c == '+'; ++c) {
+ fputc(*c, out);
+ }
break;
case EXPR_ENUM_CONSTANT: {