aboutsummaryrefslogtreecommitdiff
path: root/libjava
diff options
context:
space:
mode:
authorMark Wielaard <mark@klomp.org>2002-07-16 21:08:25 +0000
committerMark Wielaard <mark@klomp.org>2002-07-16 21:08:25 +0000
commit96d83326abab17c9754d033646624e81519204bd (patch)
tree3e380de728b702efb4e4e65f00f56b0e894af5b0 /libjava
parent3f93c487e7625f25c01f975188007fe3990e7988 (diff)
* java/io/StreamTokenizer.java (pushBack): Update documentation.
(whitespaceChars): call resetChar(). git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@55496 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava')
-rw-r--r--libjava/ChangeLog5
-rw-r--r--libjava/java/io/StreamTokenizer.java18
2 files changed, 14 insertions, 9 deletions
diff --git a/libjava/ChangeLog b/libjava/ChangeLog
index b8981122027..242638f5d95 100644
--- a/libjava/ChangeLog
+++ b/libjava/ChangeLog
@@ -1,3 +1,8 @@
+2002-07-16 Mark Wielaard <mark@klomp.org>
+
+ * java/io/StreamTokenizer.java (pushBack): Update documentation.
+ (whitespaceChars): call resetChar().
+
2002-07-15 Tom Tromey <tromey@redhat.com>
* Makefile.in: Rebuilt.
diff --git a/libjava/java/io/StreamTokenizer.java b/libjava/java/io/StreamTokenizer.java
index f2e39698ca6..5b3533b633d 100644
--- a/libjava/java/io/StreamTokenizer.java
+++ b/libjava/java/io/StreamTokenizer.java
@@ -1,5 +1,5 @@
/* StreamTokenizer.java -- parses streams of characters into tokens
- Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation
+ Copyright (C) 1998, 1999, 2000, 2001, 2002 Free Software Foundation
This file is part of GNU Classpath.
@@ -554,16 +554,13 @@ public class StreamTokenizer
}
/**
- * This method returns the current line number. Note that if the
- * <code>pushBack()</code> method is called, it has no effect on the
- * line number returned by this method.
- *
- * @return The current line number
+ * Puts the current token back into the StreamTokenizer so
+ * <code>nextToken</code> will return the same value on the next call.
+ * May cause the lineno method to return an incorrect value
+ * if lineno is called before the next call to nextToken.
*/
public void pushBack()
{
- // pushBack may cause the lineno method to return an incorrect value
- // if lineno is called before the next call to nextToken.
pushedBack = true;
}
@@ -670,7 +667,10 @@ public class StreamTokenizer
if (hi > 255)
hi = 255;
for (int i = low; i <= hi; i++)
- whitespace[i] = true;
+ {
+ resetChar(i);
+ whitespace[i] = true;
+ }
}
/**