Scala was the first ML family language I learned. I tried to love it, but found I needed help learning it, so I turned to Haskell hoping for a better understanding of some of Scala's type system and other ML concepts. Then I fell in love with Haskell.
Equally complex, if not moreso, and not any easier, but it felt simpler since it focused on a single paradigm instead of attempting to mix two big ones, and the whitespace-enforced readability and uniformity helped reduce cognitive load while learning and working with it. Great performance too, C-like in some cases with expert optimizations, and a range of concurrency and parallelization options.
yep. When I first tasted Scala it seemed great, but the having abstractions that leak less (haskell) is something I really appreciate.
And there's something about Scala using traits for everything that rubs me the wrong way.
Stuff like this I still find odd, mixing abstract classes with functions and inheritance.
abstract class IntSeqBuffer extends SeqBuffer {
type U = Int
}
object AbstractTypeTest1 extends App {
def newIntSeqBuf(elem1: Int, elem2: Int): IntSeqBuffer =
new IntSeqBuffer {
type T = List[U]
val element = List(elem1, elem2)
}
val buf = newIntSeqBuf(7, 8)
}
Comments
Scala was the first ML family language I learned. I tried to love it, but found I needed help learning it, so I turned to Haskell hoping for a better understanding of some of Scala's type system and other ML concepts. Then I fell in love with Haskell.
Equally complex, if not moreso, and not any easier, but it felt simpler since it focused on a single paradigm instead of attempting to mix two big ones, and the whitespace-enforced readability and uniformity helped reduce cognitive load while learning and working with it. Great performance too, C-like in some cases with expert optimizations, and a range of concurrency and parallelization options.
yep. When I first tasted Scala it seemed great, but the having abstractions that leak less (haskell) is something I really appreciate.
And there's something about Scala using traits for everything that rubs me the wrong way.
Stuff like this I still find odd, mixing abstract classes with functions and inheritance.
My only issue with Scala is that I prefer the ML syntax more, given that my first FP language was Caml Light.