News for hackers. Stuff that matters.
Re:The Evolution of a Haskell Programmer (2001) by eru on Monday February 08, 2016 @06:14PM (#11061691)
> Do note that Haskell is moving forward all the time, and at a rate faster than mainstream is adopting these ideas.

In some sense, yes. On the other hand, there are diminishing returns. As an example, the increase in software quality from a Java-like language adopting any of algebraic data types, parametric polymorphism or first class higher order functions is probably much bigger than Haskell moving to full on dependent types.

Re:The Evolution of a Haskell Programmer (2001) by wereHamster on Monday February 08, 2016 @11:58PM (#11063195)
I have yet to find a mainstream language which implements any of those features well. Show me one which didn't have and now has proper ADTs.
Re:The Evolution of a Haskell Programmer (2001) by eru on Tuesday February 09, 2016 @12:26AM (#11063304)
Depends on how high you set your standards. Ie Python mostly has higher order functions that work, even though for mostly syntax reasons they interact badly with mutating variables---a bit of sugar would help a lot.

In any case, your point stands and complements mine.

(Apropos ADTs, did Scala always have them? From what I can tell their syntax is pretty awkward, though.

Google's Protobuf, which in some sense denotes a type system, even if not a programming language, did get something like ADTs: https://developers.google.com/protocol-buffers/docs/proto3#o...

I am pretty lenient, and would go for anything that resembles a compiler-enforced tagged union. (Think C-style union.))

Re:The Evolution of a Haskell Programmer (2001) by GFK_of_xmaspast on Tuesday February 09, 2016 @09:48AM (#11065583)
> I am pretty lenient, and would go for anything that resembles a compiler-enforced tagged union

http://www.boost.org/doc/libs/1_60_0/doc/html/variant.html ??? (and I think it's supposed to be coming in c++17)

Re:The Evolution of a Haskell Programmer (2001) by eru on Tuesday February 09, 2016 @06:41PM (#11069738)
That's interesting, thanks! It seems this one discriminates the different possibilities by type, and not by some extra tag (like the constructor in Haskell's ADTs). I wonder how that works, if you want to write something like the `either' function (or even just write down its type in C++):

    either :: (a -> c) -> (b -> c) -> Either a b -> c