[Haskell-cafe] compilation to C, not via-C
Sam Martin
sam.martin at geomerics.com
Fri Apr 24 12:36:50 EDT 2009
Hi Everyone,
It appears the GHC compiler (and other) compile Haskell *via-C* but not
*to C*. I've never really understood why there isn't a C generation
option, or why GDC ships with its own compulsory copy of gcc.
I work in Games middleware, and am very interested in looking at how
Haskell could help us. We basically sell C++ libraries. I would like to
be able to write some areas of our libraries in Haskell, compile the
Haskell to C and incorporate that code into a C++ library.
As an example, I think Haskell would be great at doing geometry
processing. I don't want to write all our geometry processing code in
C++. I'd prefer to write a big chunk of it in Haskell and wrap that in
C++.
The pattern here is using Haskell to generate C code as the end result.
It sounds like this end result isn't that far out of reach, so I'm
curious as to why it doesn't appear to be possible at present.
Have I missed something? Is there some fundamental reason this isn't
possible? Has anyone wished for this before?
Any thoughts/help much appreciated,
Thanks,
Sam Martin
---
Lead Programmer
www.geomerics.com
More information about the Haskell-Cafe
mailing list