4 ms·
> Maybe, but it's just a generic statement about programming, it has no real value in a critique of Scala specifically. About Scala specifically? No, indeed.
by mercurial 12y ago
>
Maybe, but it's just a generic statement about programming, it has no real value in a critique of Scala specifically.
About Scala specifically? No, indeed. About languages which make it possible to create custom ASCII operators? Certainly. I don't know how the Scala culture about this is, but my experience with Haskell is that once people run with it, you get awful ASCII DSLs with cryptic operators all over the place.
> I think all companies working with Scala end up settling on a sub-set of the language that they are happy with.
So, pretty much like C++, a language that people love to hate. The problem is that, out in the wild, you're going to end up with legacy code made by people who picked a different sub-set.
- gamache 12y ago> I don't know how the Scala culture about this is, but my experience with Haskell is that once people run with it, you get awful ASCII DSLs with cryptic operators all over the place. Yes, that happened in Scala too. Luckily another set of Haskell slingers wrote us Scalaz, so it's not all bad.
- bilalhusain 12y agoIn its early stages Rust used to employ a lot of sigils (people joked that its a language which makes full use of all the keys on the keyboard), but the language has moved away with the cryptic operators and IMHO looks cleaner.
- mercurial 12y agoAFAIK, the sigils were used to express differences in data types (wrt to memory allocation scheme), which is quite different from ASCII operators. This doesn't bother me nearly as much, but it may be my Perl background.
- bilalhusain 12y agoYou are right, they were mainly around pointers. As long as they are a handful and their meaning doesn't change (as opposed to using in a DSL), its easy to get used to them. Still, I find the explicit keywords a familiar territory and better to read.
- weego 12y agoThere is an infamous library called dispatch. Someone put together http://www.flotsam.nl/dispatch-periodic-table.html http://www.flotsam.nl/dispatch-periodic-table.html to try and help other developers out when using it. I use it because it is good... but hell. The lack of discipline there is awful. The problem is that, out in the wild, you're going to end up with legacy code made by people who picked a different sub-set. This is the situation I've been in for the last year and I agree that for every point I make in praise of language flexibility this is the strongest counter-point.
- oelang 12y agoDispatch was one of the first libraries for scala, it's not really fair to use it as an example. The latest version of dispatch doesn't have that many operators anymore. http://dispatch.databinder.net/Combined+Pages.html http://dispatch.databinder.net/Combined+Pages.html
- chrisloy 12y agoDispatch is a library that I initially found irritating, because in early versions it proved extremely opinionated in it's use of futures and symbolic operators. However, as time has gone on, I've found that my coding style in Scala has evolved to the point where I want low-level libraries to work in an asynchronous way. There are now also overloaded, human-readable methods for most (if not all) of the symbolic operators. These days it is my HTTP client of choice.
- mercurial 12y agoIt's not bad, but they have some work to do to catch up with conduit's operators like $$+-.
- dragonwriter 12y ago> About Scala specifically? No, indeed. About languages which make it possible to create custom ASCII operators? Certainly. IME, its possible to be just as unreadable with the more verbose custom alphanumeric operators (functions/procedures) that every structured/OO/functional programming language lets you create as with terse non-alphanumeric symbolic operators; all that eliminating the latter does is to limit how concise [1] it is possible for even a well-designed DSL to be. [1] Note that concise isn't just terse, but also clear.