mirror of
https://github.com/servo/servo.git
synced 2025-06-14 11:24:33 +00:00
Allow sequence of nullable dictionary items in webidl
of type "sequence<Dict?> x"
This commit is contained in:
parent
1a61937031
commit
f014f15d4e
1 changed files with 5 additions and 2 deletions
|
@ -1134,7 +1134,7 @@ def getJSToNativeConversionInfo(type, descriptorProvider, failureCode=None,
|
|||
|
||||
if type.isDictionary():
|
||||
# There are no nullable dictionaries
|
||||
assert not type.nullable()
|
||||
assert not type.nullable() or (isMember and isMember != "Dictionary")
|
||||
|
||||
typeName = "%s::%s" % (CGDictionary.makeModuleName(type.inner),
|
||||
CGDictionary.makeDictionaryName(type.inner))
|
||||
|
@ -6645,7 +6645,10 @@ class CGDictionary(CGThing):
|
|||
|
||||
@staticmethod
|
||||
def makeDictionaryName(dictionary):
|
||||
return dictionary.identifier.name
|
||||
if isinstance(dictionary, IDLWrapperType):
|
||||
return CGDictionary.makeDictionaryName(dictionary.inner)
|
||||
else:
|
||||
return dictionary.identifier.name
|
||||
|
||||
def makeClassName(self, dictionary):
|
||||
return self.makeDictionaryName(dictionary)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue