On Thu, 13 Jan 2000, Arjan van IJzendoorn wrote:

  > Hello Jan,
  > 
  > > > [..write your own Clean compiler...]
  > > How difficult would this be?
  > 
  > Writing it from scratch would be lots and lots of work. Translating to
  > Haskell would also be far from easy. You can not simply throw away
  > uniqueness information. It is essential for doing side-effects.
  > 
  > > type checking the uniqueness annotations would be possible
  > 
  > Type checking in the presence of uniqueness annotations and classes is
  > ridiculously hard. When I tried to implement monads with unique types I
  > bumped into parts of the type checker that were undefined; resulting in a
  > compiler crash. I think by now they have solved this, but reinventing this
  > yourself can take a long, long time.
  > 
  > > What would be the best approach to tackle this problem?
  > 
  > I would suggest not to do it. Use Haskell if you want to fool around with
  > the source code of the compiler.
  > 
  > Bye,
  >   Arjan
  > 

So essentially, what you're saying is: in theory, you can write your own
(possibly Open Source) Clean-compiler, but in practice, you can't because
it is way too difficult. But doesn't this amount to saying: if you want the
source of a Clean compiler, you're straight out of luck? 
But then Jerzy's argument that you *could* write a Clean compiler of your
own is essentially useless; and people wanting to use Clean are restricted
to the current implementation. 

Another argument in favour of releasing the sources could be that people
could add features they wanted to Clean. E.g. suppose you wanted to use
something like Mark Jones' functional dependencies for type classes in
Clean. Now, you have to ask the good people at Hilt to do this (and they'll
probably be busy doing other useful things), and it could take a while
before it gets done (if at all). With the sources it would at least be
possible to do it yourself (it still doesn't have to be easy). So I think
not releasing the sources limits the power of the Clean language. Besides,
people hacking the sources seem to have a tendency to find bugs (and also
stand a good chance of remedying them :-) 

This is not a rant against the people at Hilt, it's just that I'm
*interested* at how Clean works...

All the best,

Jan de Wit
 

Reply via email to