45 ms·
I do not think Scala is an ML. The use of the word acceptable and indeed restricting it to an ML derivative loses the point of what Scala is supposed to be. Sca
by Dn_Ab 15y ago
I do not think Scala is an ML. The use of the word acceptable and indeed restricting it to an ML derivative loses the point of what Scala is supposed to be. Scala is supposed to be something different: a successful melding of OOP and functional. And it is the best at that I have seen. It succeeds on this better than the next biggest contender: F#, which is the most acceptable ML, IMO. F# is more typically functional, using the usual Hindley Milner Inference and sharing a core with OCaml but with significant whitespace. So it can be very succinct. Typically functional idioms like algebraic data types, Piping, point free, currying and combinators is more natural to F# than Scala's more OOP way. I prefer F# to Scala but that is merely a subjective preference.
There are a number of things that Scala does naturally that are cumbersome in other languages because of how it manages to meld a powerful combination of orthogonal features. To use Scala as just another functional language is to miss its power. Those who criticize OOP have not used a language that does it right. Abstractly, in a simplified categoric setting, we can consider OOP (objects as coalgebras) and FP (algebraic data types) as duals of each other. A proper unification of the concepts gives something more powerful than either. I think Scala comes the closest. Sure you can be 100% functional in it, or replicate Java but to call it one or the other is to make the same mistake as to say that light is both a wave and a particle and think you understand what that means.
- michaelochurch 15y agoBrilliant
- michaelochurch 15y agoBrilliant synopsis. Thanks!
- michaelochurch 15y agoBrilliant synopsis. Thanks!
- michaelochurch 15y agoBrilliant synopsis. Thanks!