Enable allTypes() for type specifiers
This commit is contained in:
@@ -77,6 +77,9 @@ def argumentsNodeToMethodSignature(node):
|
|||||||
def multipleTypeMatcher(typeNode):
|
def multipleTypeMatcher(typeNode):
|
||||||
subSignature = []
|
subSignature = []
|
||||||
|
|
||||||
|
if len(typeNode.type.children) == 0:
|
||||||
|
return allTypes()
|
||||||
|
|
||||||
for child in typeNode.type.children:
|
for child in typeNode.type.children:
|
||||||
m = typeMatcher(child)
|
m = typeMatcher(child)
|
||||||
subSignature.append(m)
|
subSignature.append(m)
|
||||||
@@ -99,6 +102,9 @@ def typeMatcher(typeNode):
|
|||||||
def listSpecifier(specifier):
|
def listSpecifier(specifier):
|
||||||
subSignature = []
|
subSignature = []
|
||||||
|
|
||||||
|
if len(specifier.children) == 0:
|
||||||
|
subSignature.append(allTypes())
|
||||||
|
|
||||||
for child in specifier.children:
|
for child in specifier.children:
|
||||||
subSignature.append(typeMatcher(child))
|
subSignature.append(typeMatcher(child))
|
||||||
|
|
||||||
@@ -108,6 +114,12 @@ def mapSpecifier(keySpecifier, valueSpecifier):
|
|||||||
keySubSignature = []
|
keySubSignature = []
|
||||||
valueSubSignature = []
|
valueSubSignature = []
|
||||||
|
|
||||||
|
if len(keySpecifier.children) == 0:
|
||||||
|
keySubSignature.append(allTypes())
|
||||||
|
|
||||||
|
if len(valueSpecifier.children) == 0:
|
||||||
|
valueSubSignature.append(allTypes())
|
||||||
|
|
||||||
for child in keySpecifier.children:
|
for child in keySpecifier.children:
|
||||||
keySubSignature.append(typeMatcher(child))
|
keySubSignature.append(typeMatcher(child))
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user