RFR: 7171390 - The "bug" describe is a typo
Hong Dai Thanh
nhahtdh at gmail.com
Fri Feb 21 10:05:02 UTC 2014
I request that JDK-7171390 be closed, since there is a typo in the bug
report
Copied from the bug report
> 1 - String r1="blah - * ^% $^& [gf]".replaceAll("[a-zA-Z0-9]", "-");
> 2 - String r2="blah - * ^% $^& [gf]".replaceAll("[0-9a-zA-z]", "-");
The regex from String r2 specifies A-z, instead of A-Z. The range A-z
includes [ ] \ ^ _ `
This explains why more characters are replaced in the output of r2.
Best regards.
More information about the core-libs-dev
mailing list