by CoffeeDregs · 15y ago · 0 comments
It turns out, Scala isn't hard because of all its language features. There are other languages that easily comparable in size to it and also support multiple paradigms. It has some syntactic flexibility that some people find offensive, but it's certainly not the difficult part of learning Scala. Scala is difficult mainly because it is so well designed that it easily enables the use of functional patterns that most people aren't familiar with. This means that to use it you have to learn a new paradigm, and most people aren't willing to put in the effort to do so.
I hear this argument a lot, but I don't think it's true. I've done a fair amount of haskell, OZ, lisp in various forms, etc, etc. I often have a hard time reading scala code, more so than any of these other languages which are also FP. Maybe it's just me, but it sure seems like other people have had the same experience. I've begun calling it statically typed perl, because my experience with it is very similar.
I feel like the compromises Scala makes are valid. I guess in the end though if you feel like Scala is unreadable then it is not the language for you. Since Scala is something I believe strongly in, I wish there were a way I could help make it more readable for you! As someone who knows both Perl and Scala well, I feel like there is a whole world of difference between the two.
I would argue that monads are the ultimate imperative style.
I would also agree that Haskell users have very little interest in it becoming mainstream.
My main gripe with Scala (in which another developer in my compilers class used it, not me), was that when reading his code I saw a lot of "magic." I'm not sure if that was better or worse, just... different.
Actually they do, and exactly for the reasons you just said. C# is one of the largest mainstream languages in terms of syntax. It's definitely a "kitchen sink" language.
Which is not to say it is a bad language. It has its uses like every language out there.
(That said, the port of Scala to .NET made the design decision to not fix this; however, the reason is not "we liked it", but "we don't want to be incompatible with Scala for the JVM": a decision I consider totally reasonable.)