HomePhabricator

fixupInsertion() variable documentation and cleanup

Description

fixupInsertion() variable documentation and cleanup

Functional changes (fixes):

  • Make writeElement() also update parentNode and parentType for openings
  • Also add to fixupStack when opening a wrapper for a text node

Non-functional changes (cleanup&docs):

  • Document all variables at the beginning of the function
  • Group variables according to where/how they're used
  • Move expectedType into writeElement()
  • Kill node, duplicates parentNode unnecessarily
  • Kill paragraphOpened, was misnamed and unnecessary
  • Rename closedElements to reopenElements

Change-Id: Ie5b4e4f30b267943048fdc170accb29139039192

Details