aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/bindings/codegen/parser/WebIDL.py
diff options
context:
space:
mode:
authorAnthony Ramine <n.oxyde@gmail.com>2015-10-16 23:21:29 +0200
committerAnthony Ramine <n.oxyde@gmail.com>2015-12-15 23:06:35 +0100
commit06947965b1635c4f5ff2aebcf5dfef35c6e95f23 (patch)
tree0872856caab3d7528875d7a61f87d5bf6277482a /components/script/dom/bindings/codegen/parser/WebIDL.py
parent432087c0ea6a5a419273b448eec62eb7549ba242 (diff)
downloadservo-06947965b1635c4f5ff2aebcf5dfef35c6e95f23.tar.gz
servo-06947965b1635c4f5ff2aebcf5dfef35c6e95f23.zip
Remove all our local patches to the WebIDL parser
All the tweaks we need can just be made through Configuration.py, and [Abstract] is being submitted upstream by Ms2ger.
Diffstat (limited to 'components/script/dom/bindings/codegen/parser/WebIDL.py')
-rw-r--r--components/script/dom/bindings/codegen/parser/WebIDL.py48
1 files changed, 40 insertions, 8 deletions
diff --git a/components/script/dom/bindings/codegen/parser/WebIDL.py b/components/script/dom/bindings/codegen/parser/WebIDL.py
index 90ec9e88921..f210d2c6028 100644
--- a/components/script/dom/bindings/codegen/parser/WebIDL.py
+++ b/components/script/dom/bindings/codegen/parser/WebIDL.py
@@ -526,8 +526,46 @@ class IDLExposureMixins():
class IDLExternalInterface(IDLObjectWithIdentifier, IDLExposureMixins):
def __init__(self, location, parentScope, identifier):
- raise WebIDLError("Servo does not support external interfaces.",
- [self.location])
+ assert isinstance(identifier, IDLUnresolvedIdentifier)
+ assert isinstance(parentScope, IDLScope)
+ self.parent = None
+ IDLObjectWithIdentifier.__init__(self, location, parentScope, identifier)
+ IDLExposureMixins.__init__(self, location)
+ IDLObjectWithIdentifier.resolve(self, parentScope)
+
+ def finish(self, scope):
+ IDLExposureMixins.finish(self, scope)
+ pass
+
+ def validate(self):
+ pass
+
+ def isExternal(self):
+ return True
+
+ def isInterface(self):
+ return True
+
+ def isConsequential(self):
+ return False
+
+ def addExtendedAttributes(self, attrs):
+ assert len(attrs) == 0
+
+ def resolve(self, parentScope):
+ pass
+
+ def getJSImplementation(self):
+ return None
+
+ def isJSImplemented(self):
+ return False
+
+ def getNavigatorProperty(self):
+ return None
+
+ def _getDependentObjects(self):
+ return set()
class IDLPartialInterface(IDLObject):
@@ -1643,9 +1681,6 @@ class IDLDictionary(IDLObjectWithScope):
self.identifier.name,
[member.location] + locations)
- def module(self):
- return self.location.filename().split('/')[-1].split('.webidl')[0] + 'Binding'
-
def addExtendedAttributes(self, attrs):
assert len(attrs) == 0
@@ -4157,9 +4192,6 @@ class IDLCallback(IDLObjectWithScope):
self._treatNonCallableAsNull = False
self._treatNonObjectAsNull = False
- def module(self):
- return self.location.filename().split('/')[-1].split('.webidl')[0] + 'Binding'
-
def isCallback(self):
return True