top | item 12057296

(no title)

ctb_mg | 9 years ago

As someone who knows zero haskell, and little markdown, can someone explain how this works?

haskell.org [1] says there is "bird style" and "LaTeX style" ways of marking off code vs documentation, and I see neither in the linked file. Is it the "```haskell" blocks?

[1] https://wiki.haskell.org/Literate_programming#Haskell_and_li...

discuss

order

danidiaz|9 years ago

Yes, that seems to be the syntax used by literate markdown https://ghc.haskell.org/trac/ghc/wiki/LiterateMarkdown

ahakki|9 years ago

Just some additional info, because literate markdown support is not completly frictionless yet:

To so this yourself you need to add the --markdown-unlit flag to ghc and add the package "markdown-unlit" to your dependencies. Additionally you have to symlink your .md file to .lhs, as ghc does not look at .md files (even with the --markdown-unlit flag, which I find kinda sad)

ahakki|9 years ago

[deleted]