diff options
author | Anthony Ramine <n.oxyde@gmail.com> | 2015-09-11 23:55:20 +0200 |
---|---|---|
committer | Anthony Ramine <n.oxyde@gmail.com> | 2015-09-13 19:46:28 +0200 |
commit | c25085f68a86e2885d77146add097f9f796c96ac (patch) | |
tree | 6e5f7040cd7b4ba5cfb421049485782f44b22740 /components/script/parse/html.rs | |
parent | 941f7dc04bc02ad196e86c5167ea292477fb7284 (diff) | |
download | servo-c25085f68a86e2885d77146add097f9f796c96ac.tar.gz servo-c25085f68a86e2885d77146add097f9f796c96ac.zip |
Introduce [Abstract] to mark non-leaf interfaces
Some interfaces like Node, CharacterData and HTMLTableCellElement are never
instantiated directly, only their descendant interfaces are. Those are marked
with [Abstract] to set their type_id to None instead of having dummy values
in the TypeId enums.
Diffstat (limited to 'components/script/parse/html.rs')
-rw-r--r-- | components/script/parse/html.rs | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/components/script/parse/html.rs b/components/script/parse/html.rs index 250b128e5f3..8aec2e816e4 100644 --- a/components/script/parse/html.rs +++ b/components/script/parse/html.rs @@ -184,8 +184,6 @@ impl<'a> Serializable for &'a Node { traversal_scope: TraversalScope) -> io::Result<()> { let node = *self; match (traversal_scope, node.type_id()) { - (_, NodeTypeId::Node) => unreachable!(), - (_, NodeTypeId::CharacterData(CharacterDataTypeId::CharacterData)) => unreachable!(), (_, NodeTypeId::Element(..)) => { let elem = ElementCast::to_ref(node).unwrap(); let name = QualName::new(elem.namespace().clone(), |