Whatever scalafmt defaults to
It's not ready yet though, is it?
-
-
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
Ideally, better to let scalafmt does what it does. In other words, it doesn't matter as long as it is consistent
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
View this poll result sideways
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
I'm glad to see such a consensus to the option I voted
-
Yeah, there does seem to be consensus, though I can't think of any other keywords that are written adjacent to parentheses without whitespace in between, so I'm a bit surprised it's so accepted. (However, I commonly did this with `if` and `for` when other people didn't.)
- Show replies
New conversation -
-
-
extension[T](value: X) makes it feel like your are defining method "extension". I like Option 1 instead, because it makes it clearer that "extension" is just a keyword.
-
Fully agree
End of conversation
New conversation -
-
-
Why would you have type parameter T of extension if receiver object is of type X?
-
The T can still be used in the method, though. But, yes... that's a less likely scenario!
- Show replies
New conversation -
-
-
@TomekGodzik how scalafmt handle that by default? -
That would be `extension [A, B](a: A)` currently :s
- Show replies
New conversation -
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.