[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

java/text/ (compileFormat)

From: Ito Kazumitsu
Subject: java/text/ (compileFormat)
Date: Fri, 28 Nov 2003 01:06:43 +0900
User-agent: EMH/1.10.0 SEMI/1.13.7 (Awazu) FLIM/1.13.2 (Kasanui) Emacs/21.2 (i386-unknown-freebsd4.7) MULE/5.0 (SAKAKI)


Browsing GNU Classpath's CVS log, I found:

2003-10-02  Michael Koch  <address@hidden>

        * java/text/
        (compileFormat): Character.isLetter(char) allows too much characters.
        Replace it with Character.isLowerCase(char) ||

I think this change has something to do with the bug report:,

where I suggested to use

   (thisChar >= 'A' && thisChar <= 'Z') || (thisChar >= 'a' && thisChar <= 'z')

instead of


Why do we use "Character.isLowerCase(char) || Character.isUpperCase(char)"
when the API doc clearly says, "Within date and time pattern strings,
unquoted letters from 'A' to 'Z' and from 'a' to 'z' are interpreted
as pattern letters representing the components of a date or time string"?

I am afraid "Character.isLowerCase(char) || Character.isUpperCase(char)"
also allows too many characters,  including Greek or Slavic alphabet
or even Japanese Zenkaku alphabet.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]