From 38206a5304739c5e986c26e71186b74db0a5af5b Mon Sep 17 00:00:00 2001 From: Andy Clement Date: Mon, 29 Jul 2013 11:19:02 -0700 Subject: AspectJ 1.8 --- util/src/org/aspectj/util/LangUtil.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'util') diff --git a/util/src/org/aspectj/util/LangUtil.java b/util/src/org/aspectj/util/LangUtil.java index 7a7149698..cf929b7b5 100644 --- a/util/src/org/aspectj/util/LangUtil.java +++ b/util/src/org/aspectj/util/LangUtil.java @@ -74,7 +74,7 @@ public class LangUtil { try { String versionString = vm.substring(0, 3); Double temp = new Double(Double.parseDouble(versionString)); - vmVersion = temp.floatValue(); + vmVersion = temp.doubleValue(); } catch (Exception e) { vmVersion = 1.4; } @@ -106,6 +106,10 @@ public class LangUtil { public static boolean is17VMOrGreater() { return 1.7 <= vmVersion; } + + public static boolean is18VMOrGreater() { + return 1.8 <= vmVersion; + } /** * Shorthand for "if null, throw IllegalArgumentException" -- cgit v1.2.3