I am a newbie to Scala, but I have some experience in using OCaml. I am thinking to adopt the pipe operator defined in Scalaz in the follo
Scala
OCaml
Scalaz
You need to pass the "thrush" combinator a function, so the following works:
"asdf" |> length2 |> (_.length)
If you want to insert line breaks, put the operator at the end of the line:
or the following is also valid:
"asdf" .|> (length2) .|> (_.length)