-
Bug
-
Resolution: Fixed
-
P2
-
9
-
b162
-
Verified
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8177617 | 10 | Pavel Rappo | P2 | Resolved | Fixed | b04 |
The spec says:
"A version without a build number is always less than one with a build number; otherwise build numbers are compared numerically."
However, the following code prints "false":
System.out.println(Runtime.Version.parse("1.1.1").compareTo(Runtime.Version.parse("1.1.1+1")) < 0);
The same result will be for compareToIgnoreOpt.
"A version without a build number is always less than one with a build number; otherwise build numbers are compared numerically."
However, the following code prints "false":
System.out.println(Runtime.Version.parse("1.1.1").compareTo(Runtime.Version.parse("1.1.1+1")) < 0);
The same result will be for compareToIgnoreOpt.
- backported by
-
JDK-8177617 Runtime.Version.compareTo/compareToIgnoreOpt problem
-
- Resolved
-