[Haskell wikibook] Re: Cheat sheet

Heinrich Apfelmus apfelmus at quantentunnel.de
Mon May 24 08:39:41 EDT 2010

Daniel Mlot wrote:
> I took a bit of a break from the book over this week in order to give
> time to my ideas to get clearer. By the way, I just reduced my Haskell
> naivety a bit by writing an useful-ish standalone "real world" program,
> which works fine other than for being very memory hungry (still, the
> code is *so* much nicer to work with than the corresponding procedural
> implementations that I would gladly concede it a couple hundred
> megabytes to play with). Anyway...

Feel free to ask on the #haskell IRC channel or the
beginners at haskell.org mailing list for advice on your memory woes;
there's always someone around you can help.

>> Also, I'm unhappy with the current markup we have to use. It's much
>> easier to specify it in "pseudo haddock markup"
>>    -- | Last element.
>>    -->  last [1,2,3] = 3
>>    last :: [a] ->  a
>>    -- | Number of elements.
>>    -->  length [True, False] = 2
>>    length :: [a] ->  Int
>> and have a Haskell program translate that to wikitext or any other
>> format.
> That would be an interesting possibility for generating the tables...
> too bad we can't shortcut around the MediaWiki interface, and would
> likely still have to rely on it (and its hideous triple-curly-bracket
> syntax)  for maintenance of the cheat sheets after they are uploaded. By
> the way, that reminds me I used to have a neat Firefox add-on which
> allowed to edit the contents of any text area into vim; it could become
> handy in such circumstances.

I was thinking about putting both the source for the cheat sheet and the
Haskell program that translates it on the talk page, and instruct people
to make changes there. Not ideal, but should work.

Speaking of Haskell program: that would make another good exercise for
you, if you're up to it. ;)

In the very long run, I'm thinking about moving away from the wikibook
technology and creating something with a Haskell backend. This way, we'd
have complete freedom to use our own markup and could experiment a
little with embedded reader comments and other things. But this is just
wishful thinking for now.

> By the way, a note about the chapters: I am missing a bit of doing some
> actual writing, so if I feel brave enough I will try to contribute to
> some of the missing bits of Basics. The most likely targets for me would
> be the initial explanation of numerical types in "Type basics" or some
> of the list comprehension introduction that will become "Working with
> lists".

Sure, go ahead. :)

Heinrich Apfelmus


More information about the Wikibook mailing list