News for hackers. Stuff that matters.
Re:Implementing a JIT Compiled Language with Haskell and LLVM by Peaker on Saturday September 12, 2015 @04:10PM (#10209177)
I think the greatest features of the ML family for compiler development are great AST representations (as algebraic data types) with pattern-matching. When you change the AST, it is very easy to go and fix all the AST transformations to handle less/more cases or fix the types.

There are other great features for compiler development in the ML family, but almost all of them revolve around static types.

Can you explain what you mean when you say Lisp is excellent for compiler development? When changing the AST, how would you go about changing all the code that needs to be changed?

Re:Implementing a JIT Compiled Language with Haskell and LLVM by sklogic on Saturday September 12, 2015 @04:33PM (#10209264)
ML got ADTs and pattern matching out of the box. Fine. With Lisp you can quickly build your own ADTs, with some enhanced functionality which is not possible in *ML family.

See a couple of examples of this:

[1] http://www.cs.indiana.edu/~dyb/pubs/nano-jfp.pdf

[2] https://github.com/combinatorylogic/mbase

Re:Implementing a JIT Compiled Language with Haskell and LLVM by Peaker on Sunday September 13, 2015 @09:38AM (#10211348)
> > When changing the AST, how would you go about changing all the code that needs to be changed?

Is there an answer to this question?

Re:Implementing a JIT Compiled Language with Haskell and LLVM by sklogic on Sunday September 13, 2015 @11:34AM (#10211706)
Have you seen Nanopass or MBase? They address this very question.