aboutsummaryrefslogtreecommitdiffstats
path: root/resources
diff options
context:
space:
mode:
authorbors-servo <lbergstrom+bors@mozilla.com>2017-06-17 02:21:19 -0700
committerGitHub <noreply@github.com>2017-06-17 02:21:19 -0700
commit9c2dffdf72efe4274bb514407edc552b14fc0a4d (patch)
tree2471c53243fbbe31d64c297cb38f3ce392204b5b /resources
parentf56d19227641a2ffeadd30a9673a13cd9a192841 (diff)
parentad649bb7e3a893072f35167b2af1b1e43d5cfc25 (diff)
downloadservo-9c2dffdf72efe4274bb514407edc552b14fc0a4d.tar.gz
servo-9c2dffdf72efe4274bb514407edc552b14fc0a4d.zip
Auto merge of #17037 - cynicaldevil:impl-Sink, r=nox
Added Async HTML Tokenizer Design: I realized having two different parsers for sync and async was wrong, because the API for both was fundamentally the same. All I needed to do was create another Tokenizer, because `ParseNode` ( representation for nodes which are yet to be created) is used by the TreeBuilder and the Sink, and the `Tokenizer` is the 'lowermost' type concerned with these two types. Therefore, I created one and placed it in `async_html.rs`, and also created a new Sink which deals with `ParseNode`s. I changed the methods in ServoParser to take an `async` argument too, which decides which Tokenizer will be used. The Tokenizer isn't exactly *async* for now, but this PR separates action creation from execution, which allows the async behaviour to be implemented later. Right now, all actions are executed soon after they are created. The Sink consists of two Hashmaps, `nodes`, which contains the actual nodes, with the key being their corresponding `ParseNode`'s id, and `parse_node_data`, which contains metadata about the nodes. It's still a bit rough, (I can't figure out how to deal with `complete_script` and `is_mathml_annotation_xml_integration_point`, along with some other parts I wrote in a hurry), but I believe the overall design is sound. I'd like to hear what you think about it. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/17037) <!-- Reviewable:end -->
Diffstat (limited to 'resources')
-rw-r--r--resources/prefs.json1
1 files changed, 1 insertions, 0 deletions
diff --git a/resources/prefs.json b/resources/prefs.json
index 3c8203a0972..8e28e622e7a 100644
--- a/resources/prefs.json
+++ b/resources/prefs.json
@@ -10,6 +10,7 @@
"dom.permissions.enabled": false,
"dom.permissions.testing.allowed_in_nonsecure_contexts": false,
"dom.serviceworker.timeout_seconds": 60,
+ "dom.servoparser.async_html_tokenizer.enabled": false,
"dom.testable_crash.enabled": false,
"dom.testbinding.enabled": false,
"dom.webvr.enabled": false,