[kaffe] Bug report (java.io.StreamTokenizer)
hemppah at cc.jyu.fi
Mon Jun 30 05:10:01 PDT 2003
On Mon, 2003-06-30 at 13:06, Ito Kazumitsu wrote:
> In message "Re: [kaffe] Bug report (java.io.StreamTokenizer)"
> on 03/06/30, Hermanni Hyytiälä <hemppah at cc.jyu.fi> writes:
> > According to the JLS (first edition), the nextToken-method of
> > java.io.StreamTokenizer class has the following lexical order:
> > whitespace
> > numeric character
> > alphabetic character
> > comment character
> > string quote character
> > comment //
> > comment /*
> I see. But this rule seems to have been ignored even by
> Sun's implementation.
> (1) Kaffe's java.io.StreamTokenizer.java has this comment:
> /* Contrary to the description in JLS 1.ed,
> C & C++ comments seem to be checked
> before other comments. That actually
> make sense, since the default comment
> character is '/'.
Do you know what this comment is based on?
> (2) Comment characters must be checked before alphabetic characters
> and Sun's java.io.StreamTokenizer seems to do so. Otherwise,
> NBIO you mentioned cannot run properly.
Hm, have you tested and if so how? Or does literature mentions about
this? After a quick thought, I don't see any problem in the lexical
order which is defined in nextToken-method of java.io.StreamTokenizer
(JLS, 1st edition).
More information about the kaffe