 : push-doctype-system-identifier ( ch document -- )
     doctype>> system-identifier>> push ;
 
-GENERIC: tree-insert* ( document obj tree-insert-mode -- document )
+GENERIC: tree-insert* ( document obj tree-insertion-mode -- document )
 M: initial-mode tree-insert*
     drop {
         { CHAR: \t [ ] }

quirks-mode?
fostering-parent?
tree
tree-insert-mode
doctype
tag
end-tag

: <document> ( -- document )
    document new
        V{ } clone >>tree
        initial-mode >>tree-insertion-mode
        <doctype> >>doctype
        SBUF" " clone >>attribute-name
        SBUF" " clone >>attribute-value
