Skip to content

Commit

Permalink
Showing 2 changed files with 5 additions and 2 deletions.
1 change: 0 additions & 1 deletion spec/truffle/tags/core/string/modulo_tags.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
fails:String#% raises an ArgumentError for unused arguments when $DEBUG is true
fails:String#% raises an ArgumentError for huge precisions for %s
fails:String#% behaves as if calling Kernel#Float for %e arguments, when the passed argument does not respond to #to_ary
fails:String#% behaves as if calling Kernel#Float for %e arguments, when the passed argument is hexadecimal string
fails:String#% behaves as if calling Kernel#Float for %E arguments, when the passed argument does not respond to #to_ary
Original file line number Diff line number Diff line change
@@ -336,7 +336,11 @@ public LookAheadResult getNum(int startI, int end) {

Integer result;
if (sb.length() > 0) {
result = Integer.parseInt(sb.toString());
try {
result = Integer.parseInt(sb.toString());
} catch (NumberFormatException nfe) {
throw new InvalidFormatException("precision too big");
}
} else {
result = null;
}

0 comments on commit 4b10c01

Please sign in to comment.