This is the mail archive of the
mauve-discuss@sources.redhat.com
mailing list for the Mauve project.
Re: StreamTokenizer
- From: Brian Jones <cbj at gnu dot org>
- To: Daryl Lee <dlee at altaregos dot com>
- Cc: Mauve Discuss <mauve-discuss at sources dot redhat dot com>
- Date: 14 Sep 2002 20:14:22 -0400
- Subject: Re: StreamTokenizer
- References: <20020914182618.A7147@tigger>
Daryl Lee <dlee@altaregos.com> writes:
> I believe the following patch might be useful in
> gnu/testlet/java/io/StreamTokenizer/Test.java.
>
> 69c69
> < tokenize (harness, "(a).(b)", x1);
> ---
> > tokenize (harness, "(a)5(b)", x1);
>
> (This is a straight diff, not a CVS diff; I've never submitted a
> patch, so someone tell me if this is the wrong protocol.)
>
> The original string causes classpath's number parser to fail, trying
> to parse a bare '.'. (See §3.10.2 of the Java Language
> Specification.) I believe a better solution is to make
> StreamTokenizer handle the NumberFormatException thrown by Double,
> but that is an argument for others to conduct.
Daryl, is how Sun's 1.4 implementation behaves? I see that
StreamTokenizer.parseNumbers() would have '.' treated as a 'numeric'
value.
Brian
--
Brian Jones <cbj@gnu.org>