14 years into Scala, I'm experimenting with a new way of formatting my code. I've started column-aligning each opening `(` of explicit/implicit parameter block, and the `:` of the return type in method/class definitions, with a four-space indent for long lines. Liking it so far.
-
Show this thread
-
6 replies 2 retweets 7 likesShow this thread -
Replying to @propensive
What is that return type, with the pipes and the tilde?
1 reply 0 retweets 0 likes -
Replying to @loewenheim
It's a monad, a bit like `Try`, which encodes all possible error types, a bit like typelevel checked exceptions. The pipes are aliases which construct an intersection type, which allows the types to match if they're reordered.
2 replies 0 retweets 1 like -
Replying to @propensive
Interesting, where can I read about it? At first I thought it was a dotty type disjunction.
1 reply 0 retweets 0 likes
I gave a talk about it here: https://www.youtube.com/watch?v=GBk8Pxgy7qM … - but not in much detail. I've got plans to publish it as a library (called "Mitigation"), but haven't got round to it yet. It's used throughout Fury, so I'll prepare it as part of Fury's release. :)
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.