module watt.markdown.parser

Markdown parser.

Code Map

//! Markdown parser.
module watt.markdown.parser;


//! Internal representation of a link.
class LinkReference
{
public:
	enum Stage
	{
		Opening,
		Label,
		ClosingColon,
		Url,
		Title,
		Done,
	}


public:
	label: string;
	url: string;
	title: string;
	titleSentinel: dchar;
	stage: Stage;
	lines: string[];


public:
	this() { }
	fn addLines(p: Parser) { }
}

//! Parse a string of markdown, ready for processing into output.
fn parse(str: string) Document { }
fn parse(str: string) Document

Parse a string of markdown, ready for processing into output.

class LinkReference

Internal representation of a link.

fn isLazyContinuation(p: Parser, str: string) bool

Basically, in non-spec-ese, a lazy continuation line is a line that would just be parsed as a paragraph. Not a list, not a quote, etc. (It's lazy because it acts as if the block structure indicator was written before it). Very incomplete atm.