News for hackers. Stuff that matters.
Re:A Taste of Haskell by harpocrates on Monday October 24, 2016 @07:03PM (#12783689)
For me, I think the answer to this is really that Haskell is pure and immutable.

Equational reasoning[1] is immensely useful when debugging. It isn't unusual to debug pieces of Java code that look like this.

    MyClass c = new MyClass(..);
    c.method1(..);
    c.method2(..);
    c.method3(..);
    assert(c.someField == ..) // fails!
To figure what went wrong, you have to read through all three methods and depending on whether you have dynamic dispatch coming into play, you might need to read through _multiple_ versions of all three methods.

[1]: http://www.haskellforall.com/2013/12/equational-reasoning.ht...

There are no comments on this comment yet.