This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Copyright Shunsuke Sogame 2008-2009. | |
// Distributed under the terms of an MIT-style license. | |
// See: "Packrat Parsers Can Support Left Recursion" | |
package mada.peg |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package mada.vec | |
private[mada] object TripleVector { | |
def apply[A](v: Vector.Triple[A]): Vector[A] = v._1(v._2, v._3) | |
} | |
private[mada] object VectorTriple { | |
def apply[A](v: Vector[A]): Vector.Triple[A] = (v, v.start, v.end) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package mada.vec | |
/* | |
private[mada] object TriplesVector { | |
def apply[A](from: Vector[Vector.Triple[A]]): Vector[Vector[A]] = from match { | |
case from: VectorTriples[_] => from.from // conversion fusion | |
case _ => new TriplesVector(from) | |
} | |
} | |
NewerOlder