Type1Lexer.java (pdfbox-2.0.23-src) | : | Type1Lexer.java (pdfbox-2.0.24-src) | ||
---|---|---|---|---|
skipping to change at line 273 | skipping to change at line 273 | |||
radix = sb; | radix = sb; | |||
sb = new StringBuilder(); | sb = new StringBuilder(); | |||
c = getChar(); | c = getChar(); | |||
} | } | |||
else if (sb.length() == 0 || !hasDigit) | else if (sb.length() == 0 || !hasDigit) | |||
{ | { | |||
// failure | // failure | |||
buffer.reset(); | buffer.reset(); | |||
return null; | return null; | |||
} | } | |||
else | else if (c != 'e' && c != 'E') | |||
{ | { | |||
// integer | // integer | |||
buffer.position(buffer.position() -1); | buffer.position(buffer.position() -1); | |||
return new Token(sb.toString(), Token.INTEGER); | return new Token(sb.toString(), Token.INTEGER); | |||
} | } | |||
// required digit | // required digit | |||
if (Character.isDigit(c)) | if (Character.isDigit(c)) | |||
{ | { | |||
sb.append(c); | sb.append(c); | |||
c = getChar(); | c = getChar(); | |||
} | } | |||
else | else if (c != 'e' && c != 'E') | |||
{ | { | |||
// failure | // failure | |||
buffer.reset(); | buffer.reset(); | |||
return null; | return null; | |||
} | } | |||
// optional digits | // optional digits | |||
while (Character.isDigit(c)) | while (Character.isDigit(c)) | |||
{ | { | |||
sb.append(c); | sb.append(c); | |||
c = getChar(); | c = getChar(); | |||
} | } | |||
// optional E | // optional E | |||
if (c == 'E') | if (c == 'E' || c == 'e') | |||
{ | { | |||
sb.append(c); | sb.append(c); | |||
c = getChar(); | c = getChar(); | |||
// optional minus | // optional minus | |||
if (c == '-') | if (c == '-') | |||
{ | { | |||
sb.append(c); | sb.append(c); | |||
c = getChar(); | c = getChar(); | |||
} | } | |||
End of changes. 3 change blocks. | ||||
3 lines changed or deleted | 3 lines changed or added |