engine: Range should never return children results

This commit is contained in:
William Ballenthin
2020-06-28 11:29:36 -06:00
parent a355f2f0c6
commit cb8fedc1b9

View File

@@ -155,7 +155,7 @@ class Range(Statement):
def evaluate(self, ctx):
if self.child not in ctx:
return Result(False, self, [self.child])
return Result(False, self, [])
count = len(ctx[self.child])
return Result(self.min <= count <= self.max, self, [], locations=ctx[self.child])