diff options
author | sbucher <sbucher@epfl.ch> | 2004-08-19 13:46:10 +0000 |
---|---|---|
committer | sbucher <sbucher@epfl.ch> | 2004-08-19 13:46:10 +0000 |
commit | ce53d0dc9cb2a1b1cdd27d9b2a3c9b682e03e8de (patch) | |
tree | e73085f0fc7b81e70f5dc2abdc9c91a99fe46356 /sources | |
parent | 9802b472cca1438985cc2a7b5bb72f7e21f6231a (diff) | |
download | scala-ce53d0dc9cb2a1b1cdd27d9b2a3c9b682e03e8de.tar.gz scala-ce53d0dc9cb2a1b1cdd27d9b2a3c9b682e03e8de.tar.bz2 scala-ce53d0dc9cb2a1b1cdd27d9b2a3c9b682e03e8de.zip |
make now initializes parser before returning it
Diffstat (limited to 'sources')
-rw-r--r-- | sources/scala/xml/parsing/ParserFactory.scala | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sources/scala/xml/parsing/ParserFactory.scala b/sources/scala/xml/parsing/ParserFactory.scala index 95b734b3b3..99126fd397 100644 --- a/sources/scala/xml/parsing/ParserFactory.scala +++ b/sources/scala/xml/parsing/ParserFactory.scala @@ -13,13 +13,15 @@ object ParserFactory { } def make(theHandle:ConstructingHandler, input:Iterator[Char]): ConstructingParser = { - new ConstructingParser() { + val p = new ConstructingParser() { val it = input; override val handle = theHandle; def nextch = { ch = it.next; pos = pos + 1; } def init = { ch = it.next; pos = 0; } override val preserveWS = true; - } + }; + p.init; + p } } |