aboutsummaryrefslogtreecommitdiffstats
path: root/util
diff options
context:
space:
mode:
Diffstat (limited to 'util')
-rw-r--r--util/src/org/aspectj/util/LangUtil.java6
1 files changed, 5 insertions, 1 deletions
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"