You're welcome to look at Blink's implementation of tree construction.
 That might be a good way of seeing what data structure might be
useful.  The work is split into two major objects:

https://chromium.googlesource.com/chromium/blink/+/master/Source/core/html/parser/HTMLTreeBuilder.h
https://chromium.googlesource.com/chromium/blink/+/master/Source/core/html/parser/HTMLConstructionSite.h

The HTMLTreeBuilder dispatches the token and HTMLConstructionSite does
the actual tree construction.

Adam


On Sun, Jun 23, 2013 at 3:02 AM, Mohammad Al Houssami (Alumni)
<mh...@mail.aub.edu> wrote:
> Hello All,
>
> I am building an HTML5 parser according to the specs on the whatwg website. I 
> am currently in the tree construction stage and it seems to be so complex to 
> have a general view of what is happening by reading the specs or at least 
> know what things are needed ( like node types element types and the variables 
> of each..) Is there any place where these things are listed or maybe an 
> explanation of the tree construction stage that explains what is happening 
> during in a general view?
>
> Any help is much appreciated :)
> Mohammad

Reply via email to