Yhc/Hacking

From HaskellWiki
Part of Yhc

(Download)

First build Yhc. If Yhc won't build on your architecture or platform using the supplied instructions, either hack the Makefile, or hack the instructions until it works perfect as described.

Picking what to hack on[edit]

Of course, most people who want to hack on Yhc probably already have something that Yhc doesn't do quite right for them. So thats often a good thing to think about.

If you have no idea, its often good to go onto the HaskellIrc channel, and talk to ndm / beelsebob / tomshackell - and i'm sure we can suggest something and help your understanding of some of the things.

There are various parts of Yhc, written in different languages, so pick the part that suits you:

  • Documentation (English) - most of it is on this Wiki, feel free to start new pages or flesh out existing ones.
  • Yhc (Haskell) - the compiler - a lot of this is quite old code and could do with modifications. Everywhere you see FIXME in the source code should be fixed.
  • Yhe (Haskell) - the Ghci equivalent - this is still under active development, and needs lots of work. A GUI based on gtk2hs is in development.
  • Yhi (C) - the runtime, this is relatively new and fresh, but if you can think of anything that needs doing.

Before you hack on anything substantial, its to avoid duplication it's probably best to mention it to someone on IRC, add it to the todo list, or email the Yhc mailing list.

Developer Documentation[edit]

Sending your patches[edit]

Depending on what your patch does, send it to the following place using darcs send:

  • Minor cleanups / bug fixes to the runtime or compiler, to shackell -AT- cs -DOT- york -DOT- ac -DOT- uk
  • Any changes to the test suite or evaluator, to ndmitchell -AT- gmail -DOT- com
  • Anything big, needing discussion, or if in doubt, to yhc -AT- haskell -DOT- org

Compiling the Prelude[edit]

One important thing to note, the prelude is very special. If you want to compile it, the options you will need are "-c -redefine -prelude" - leaving -c out gives a stack overflow.