Suppose we have the following functions:
def first(a: A): B = ???
def second(b: B): C = ???
I would like to compose them using andThen
, but the following code:
(first andThen second)(a)
results in:
<console>:14: error: missing argument list for method first
Unapplied methods are only converted to functions when a function type is expected.
You can make this conversion explicit by writing `first _` or `first(_)` instead of `first`.
(first andThen second) (1)