mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
Update to zero-copy* HTML parsing
html5ever now uses the Tendril string type to minimize copying internally, but Servo still converts from/to `String` at the boundary (which involves copying).
This commit is contained in:
parent
ea06bebca9
commit
34bfa16517
7 changed files with 81 additions and 16 deletions
|
@ -312,7 +312,7 @@ impl<'a> PrivateServoHTMLParserHelpers for &'a ServoHTMLParser {
|
|||
let mut pending_input = self.pending_input.borrow_mut();
|
||||
if !pending_input.is_empty() {
|
||||
let chunk = pending_input.remove(0);
|
||||
self.tokenizer.borrow_mut().feed(chunk);
|
||||
self.tokenizer.borrow_mut().feed(chunk.into());
|
||||
} else {
|
||||
self.tokenizer.borrow_mut().run();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue