diff options
-rw-r--r-- | src/java/com/sun/gluegen/JavaEmitter.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/java/com/sun/gluegen/JavaEmitter.java b/src/java/com/sun/gluegen/JavaEmitter.java index 60daf89..2588158 100644 --- a/src/java/com/sun/gluegen/JavaEmitter.java +++ b/src/java/com/sun/gluegen/JavaEmitter.java @@ -281,7 +281,10 @@ public class JavaEmitter implements GlueEmitter { if (optionalComment != null && optionalComment.length() != 0) { javaWriter().println(" /** " + optionalComment + " */"); } - String suffix = (type.equals("float") ? "f" : ""); + String suffix = ""; + if (type.equals("float") && !value.endsWith("f")) { + suffix = "f"; + } javaWriter().println(" public static final " + type + " " + name + " = " + value + suffix + ";"); } } |