commit 30fc41a9af1c51a99328b930c5538b093c9817b4
parent 2ebcb0486543cafc87c77332301f669c54ce4bbc
Author: Tomas Hlavaty <tom@logand.com>
Date: Wed, 14 Dec 2011 01:16:03 +0100
more 2java improvements
Diffstat:
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/unoidl2java.c b/unoidl2java.c
@@ -252,7 +252,7 @@ static void pr_const(Any x) {
Any name = caddr(x);
Any exp = cadddr(x);
pr(" public static final "); pp(type); pr(" "); pp(name); pr(" = ");
- pp(exp); pl(";");
+ pp(exp); pl(HYPER == kind(car(type)) ? "L;" : ";");
}
static void pr_typedef(Any x) { // TODO (typedef (unsigned long) T ObjectSystemID)
@@ -313,6 +313,7 @@ static void pp(Any x) {
case EXP: pp(cadr(x)); break;
case XOR: pp(cadr(x)); pr("^"); pp(caddr(x)); break;
case AND: pp(cadr(x)); pr("&"); pp(caddr(x)); break;
+ case OR: pp(cadr(x)); pr("|"); pp(caddr(x)); break;
case LSHIFT:
case RSHIFT:
case MUL:
@@ -327,6 +328,7 @@ static void pp(Any x) {
}
break;
case NOT: pr("!"); pp(cadr(x)); break;
+ case TEMPLATE: pp(cadr(x)); pr("<"); pp_list(caddr(x), ", "); pr(">"); break;
//default: pr("###"); print(x);
}
} else