diff options
author | Paul Phillips <paulp@improving.org> | 2009-05-06 15:38:18 +0000 |
---|---|---|
committer | Paul Phillips <paulp@improving.org> | 2009-05-06 15:38:18 +0000 |
commit | 98be3213152ccec134da3e7856b8096beafcc6d8 (patch) | |
tree | 8e6cb835f6ff31843ef9787cc1b551b099eb806b /test/files/run/packrat1.scala | |
parent | 5b1da4217f7f36eab1ba14b5b95667de5bda09ed (diff) | |
download | scala-98be3213152ccec134da3e7856b8096beafcc6d8.tar.gz scala-98be3213152ccec134da3e7856b8096beafcc6d8.tar.bz2 scala-98be3213152ccec134da3e7856b8096beafcc6d8.zip |
Added NoSuccess extractor to combinator lib.
Diffstat (limited to 'test/files/run/packrat1.scala')
-rw-r--r-- | test/files/run/packrat1.scala | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/test/files/run/packrat1.scala b/test/files/run/packrat1.scala index 69eb8c5fc9..26fa8e76f2 100644 --- a/test/files/run/packrat1.scala +++ b/test/files/run/packrat1.scala @@ -22,10 +22,9 @@ object Test extends Application{ object grammars extends StandardTokenParsers with PackratParsers{ - def extractResult(r : ParseResult[_]) = r match{ + def extractResult(r : ParseResult[_]) = r match { case Success(a,_) => a - case Failure(a,_) => a - case Error(a,_) => a + case NoSuccess(a,_) => a } lexical.delimiters ++= List("+","-","*","/","(",")") |