28 Dec 2011 13:35
Re: Refactoring in progress with parserTests
Gabriel Wicke <wicke <at> wikidev.net>
2011-12-28 12:35:07 GMT
2011-12-28 12:35:07 GMT
On 12/28/2011 05:45 AM, Neil Kandalgaonkar wrote: > I pulled out most of the parser-y parts from the parserTests, leaving > behind just tests. Very good, this was really needed. > However, the parser is still a bit of a monster object, hence the > deliberately silly name, ParserThingy. > > I'm trying to decompose it into a chain, roughly like: The current implementation already operates as a chain, as documented in https://www.mediawiki.org/wiki/Future/Parser_development: PEG wiki/HTML tokenizer (or other tokenizers / SAX-like parsers) | Chunks of tokens V Token stream transformations | Chunks of tokens V HTML5 tree builder | HTML 5 DOM tree V DOM Postprocessors | HTML5 DOM tree +------------------> (X)HTML serialization | V DomConverter | WikiDom(Continue reading)
RSS Feed