Created
August 14, 2013 03:47
-
-
Save joshcough/6227847 to your computer and use it in GitHub Desktop.
This file contains 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
implicit def shrinkCore[V](implicit s1: Shrink[V]): Shrink[Core[V]] = Shrink { c => | |
c match { | |
case Var(_) => Stream.empty | |
case h: HardCore => Stream.empty | |
case App(f, x) => Stream(f, x) | |
// case class Let[+V](bindings: List[Scope[Byte, Core, V]], body: Scope[Byte, Core, V]) | |
case Let(bindings, body) => Stream() // TODO: bindings, body | |
// case class Case[+V](c: Core[V], branches: Map[Byte, (Byte, Scope[Byte, Core, V])], default: Option[Scope[Unit, Core, V]]) | |
case Case(c, branches, d) => Stream(c) // TODO: branches, default | |
case Data(tag, fields) => fields.toStream | |
// case class LamDict[+V](body: Scope[Unit, Core, V]) | |
case LamDict(body) => Stream() // TODO: body | |
case AppDict(f, d) => Stream(f, d) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment