def apply(self, f, i, evaluation): "Default[f_, i___]" i = i.get_sequence() if len(i) > 2: evaluation.message("Default", "argb", 1 + len(i), 1, 3) return i = [index.get_int_value() for index in i] for index in i: if index is None or index < 1: evaluation.message("Default", "intp") return name = f.get_name() if not name: evaluation.message("Default", "sym", f, 1) return result = get_default_value(name, evaluation, *i) return result
def apply(self, f, i, evaluation): 'Default[f_, i___]' i = i.get_sequence() if len(i) > 2: evaluation.message('Default', 'argb', 1 + len(i), 1, 3) return i = [index.get_int_value() for index in i] for index in i: if index is None or index < 1: evaluation.message('Default', 'intp') return name = f.get_name() if not name: evaluation.message('Default', 'sym', f, 1) return result = get_default_value(name, evaluation, *i) return result