Esempio n. 1
0
    def visitLengthDimensionList(self,
                                 ctx: evaql_parser.LengthDimensionListContext):
        dimensions = []
        dimension_list_length = len(ctx.decimalLiteral())
        for dimension_list_index in range(dimension_list_length):
            decimal_literal = ctx.decimalLiteral(dimension_list_index)
            decimal = self.visit(decimal_literal)
            dimensions.append(decimal)

        return dimensions
Esempio n. 2
0
    def visitLengthDimensionList(self,
                                 ctx: evaql_parser.LengthDimensionListContext):
        dimensions = []
        dimension_index = 0
        for child in ctx.children:
            decimal_literal = ctx.decimalLiteral(dimension_index)
            if decimal_literal is not None:
                decimal = self.visit(decimal_literal)
                dimensions.append(decimal)
            dimension_index = dimension_index + 1

        return dimensions