Doug Ransom wrote:
> I am curious. How much faster do you think GHC would run if it were
written
> in C? Or how much slower would a C++ compiler be if it were written in
> Haskell instead of C++?
>
> It seems to me that a compiler would be an ideal candidate for writing in
a
> functional language. The number of times C++ compilers have given out on
me
> indicates that C++ is not suitable for writing anything as complicated as
a
> C++ compiler.
How much faster do you think C++ programs would be if C++ compilers were
written in Haskell? Or how much slower do you think Haskell programs would
be if Haskell compilers were written in C++? [Think "program optimization".]
On the flip side...
It seems to me that a compiler would be an ideal candidate for being written
in an imperative language. The number of times GHC has been too slow and
memory-hungry for me indicates that Haskell is not suitable for writing
anything as general-purpose as a compiler.
Food for thought. :) I'm in an equivocal mood tonight...
--FAC