parrotcode: A Markdown compiler. | |
Contents | Language Implementations | Markdown |
markdown.pir - A Markdown compiler.
as a command line (without interactive mode) :
$ parrot markdown.pbc document.text $ parrot markdown.pbc --target=parse document.text PAST HTML
or as a library :
load_bytecode 'markdown.pbc' $P0 = compreg 'markdown' $S0 = <<'MARKDOWN' Title ===== Some text. MARKDOWN $P1 = $P0.'compile'($S0) $S0 = $P1() print $S0
This is the base file for the Markdown compiler.
This file includes the parsing and grammar rules from the src/ directory, loads the relevant PGE libraries, and registers the compiler under the name 'Markdown'.
PCT::HLLCompiler
object.
source
into a String containing HTML.
args
to the Markdown compiler.http://daringfireball.net/projects/markdown/
|