More work on (and tests for) HTML5 algorithms.