λ
Size: a a a
λ
S
S
λ
Oℕ
λ
S
Oℕ
S
V
V
GP
V
NS
V
I
IK
IK
import scala.language.higherKinds
trait Foo[F[_]] {
type Typeclass[X] = F[X]
def forInt: Typeclass[Int]
}
trait Bar[T] {
def foo(t: T): String
}
class Baz extends Foo[Bar] {
override def forInt: Typeclass[Int] = _.toString
}
// new Baz().forInt.foo(4)
IK