progs/parser-combinators/comb2.sc
changeset 849 3d5ecb8f1f2f
parent 828 bdcaecdee9eb
child 906 2bf1516d730f
equal deleted inserted replaced
848:2e868b5867d8 849:3d5ecb8f1f2f
    11 
    11 
    12 
    12 
    13 // more convenience for the map parsers later on;
    13 // more convenience for the map parsers later on;
    14 // it allows writing nested patterns as
    14 // it allows writing nested patterns as
    15 // case x ~ y ~ z => ...
    15 // case x ~ y ~ z => ...
       
    16 
       
    17 
    16 
    18 
    17 case class ~[+A, +B](x: A, y: B)
    19 case class ~[+A, +B](x: A, y: B)
    18 
    20 
    19 // constraint for the input
    21 // constraint for the input
    20 type IsSeq[A] = A => Seq[_]
    22 type IsSeq[A] = A => Seq[_]