type alias A ~>| B for [T]A[T] => Option[B[T]]

This commit is contained in:
Mark Harrah 2010-08-10 08:40:14 -04:00
parent 14d1bc5282
commit 32150e7097
1 changed files with 2 additions and 0 deletions

View File

@ -17,6 +17,8 @@ trait TypeFunctions
implicit def toFn1[A,B](f: A => B): Fn1[A,B] = new Fn1[A,B] {
def [C](g: C => A) = f compose g
}
type ~>|[A[_],B[_]] = A ~> Compose[Option, B]#Apply
}
object TypeFunctions extends TypeFunctions