Skip to content

Instantly share code, notes, and snippets.

@pedrofurla
Forked from tonymorris/Function1.scala
Created November 13, 2012 04:05
Show Gist options
  • Save pedrofurla/4063865 to your computer and use it in GitHub Desktop.
Save pedrofurla/4063865 to your computer and use it in GitHub Desktop.
scala Function1
object Function1Stuff {
def flatMap[T, A, B]: Function1[T, A] => (A => Function1[T, B]) => Function1[T, B] =
sys.error("todo")
}
@pedrofurla
Copy link
Author

object Function1Stuff {
def flatMap[T, A, B]: Function1[T, A] => (A => Function1[T, B]) => Function1[T, B] =
(ta: T => A) => ( atb: A => T => B) => { (t:T) => atb(ta(t))(t) }

}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment