Comparison Haskell, Java, C and LISP

Hi, Maybe you remember my case. I was trying to compare some aspects of these languages. Well... I found that I can compare reflection, support for generics, simplicity and safe code. I just want to ask if you have more information for reflection in Haskell. I read that there is no enough for dynamics to support complete reflection. I hope someone can help me this time :) Julita

Haskell has no support for reflection whatsoever. It can support compile time meta-programming with Template Haskell. Reflection itself might be antagonistic to functional programming, I suspect it is at odds with referential transparency. Most of the work on reflection seemed based around Lisp / Scheme - Christian Queinnec's reflective interpreter in Lisp in Small Pieces uses an awful lot of set! ....

Am 18.10.2011 18:53, schrieb Stephen Tetley:
Haskell has no support for reflection whatsoever.
It can support compile time meta-programming with Template Haskell.
Reflection itself might be antagonistic to functional programming, I suspect it is at odds with referential transparency. Most of the work on reflection seemed based around Lisp / Scheme - Christian Queinnec's reflective interpreter in Lisp in Small Pieces uses an awful lot of set! ....
_______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe But is (delimited) continuation not a kind of reflection? Nicu

On Tue, Oct 18, 2011 at 08:18:17PM +0200, Nicu Ionita wrote:
Am 18.10.2011 18:53, schrieb Stephen Tetley:
Haskell has no support for reflection whatsoever.
It can support compile time meta-programming with Template Haskell.
Reflection itself might be antagonistic to functional programming, I suspect it is at odds with referential transparency. Most of the work on reflection seemed based around Lisp / Scheme - Christian Queinnec's reflective interpreter in Lisp in Small Pieces uses an awful lot of set! ....
_______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
But is (delimited) continuation not a kind of reflection?
Perhaps, if a language has built-in intrinsic support for capturing continuations (as does, say, Racket). However, Haskell has no such support. Continuations in Haskell are "simulated" within a special monad; there is no real reflection going on at all. -Brent

If i understand correctly, what we called generics is what so called
reflection. It allow you to introspect type structure.
http://haskell.org/ghc/docs/latest/html/libraries/ghc-prim-0.2.0.0/GHC-Gener...
On Wed, Oct 19, 2011 at 12:03 AM, yrazes
Hi,
Maybe you remember my case. I was trying to compare some aspects of these languages. Well... I found that I can compare reflection, support for generics, simplicity and safe code. I just want to ask if you have more information for reflection in Haskell. I read that there is no enough for dynamics to support complete reflection. I hope someone can help me this time :)
Julita
_______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
participants (5)
-
Brent Yorgey
-
Nicu Ionita
-
Stephen Tetley
-
yi huang
-
yrazes