diff -r 0eaa1851a5b6 -r db0ff630bbb7 exps/bit.scala --- a/exps/bit.scala Sat Mar 16 11:15:22 2019 +0000 +++ b/exps/bit.scala Thu Apr 11 17:37:00 2019 +0100 @@ -392,10 +392,10 @@ def erase(r: ARexp) : Rexp = r match{ case AZERO => ZERO case AONE(_) => ONE - case APRED(bs, f, s) => PRED(f, s) - case AALTS(bs, rs) => ALTS(rs.map(erase(_))) - case ASEQ(bs, r1, r2) => SEQ (erase(r1), erase(r2)) - case ASTAR(cs, r)=> STAR(erase(r)) + case APRED(_, f, s) => PRED(f, s) + case AALTS(_, rs) => ALTS(rs.map(erase(_))) + case ASEQ(_, r1, r2) => SEQ(erase(r1), erase(r2)) + case ASTAR(_, r)=> STAR(erase(r)) } @@ -442,9 +442,9 @@ def flats(rs: List[ARexp]): List[ARexp] = rs match { case Nil => Nil - case AZERO :: rs1 => flats(rs1) - case AALTS(bs, rs1) :: rs2 => rs1.map(fuse(bs, _)) ::: flats(rs2) - case r1 :: rs2 => r1 :: flats(rs2) + case AZERO::rs1 => flats(rs1) + case AALTS(bs, rs1)::rs2 => rs1.map(fuse(bs, _)) ::: flats(rs2) + case r1::rs2 => r1::flats(rs2) } def stack(r1: ARexp, r2: ARexp) = r1 match { @@ -738,6 +738,17 @@ println(strings(pders_simp(qs.toList, q))) +val w : Rexp = ((("a" | "b") | "b".%) | "ab") ~ ("a".% | ("b" | "b")) +val ws = "ab" + +lexing(w, ws) +blexing_simp(w, ws) + + + + + + System.exit(0)