

def AddArg(self, arg):
    'Adds a new arg to this expression.\n\n    Args:\n       arg: The argument to add (string).\n\n    Returns:\n      True if this arg is the last arg, False otherwise.\n\n    Raises:\n      ParseError: If there are too many args.\n    '
    self.args.append(arg)
    if (len(self.args) > self.number_of_args):
        raise ParseError('Too many args for this expression.')
    elif (len(self.args) == self.number_of_args):
        return True
    return False

dataset/ETHPy150Open google/grr/grr/lib/lexer.py Expression.AddArg/original