def runMethod(self, method, args, namedArgs): machine = SmallCaps(method, self.closure, self.globals) # print "--- Running", self.displayName, atom, args # Push the arguments onto the stack, backwards. machine.push(namedArgs) for arg in reversed(args): machine.push(arg) machine.push(NullObject) machine.push(namedArgs) machine.run() return machine.pop()
def runMatcher(self, code, message, ej): machine = SmallCaps(code, self.closure, self.globals) machine.push(message) machine.push(ej) machine.run() return machine.pop()
def runMatcher(self, code, message, ej): machine = SmallCaps(code, None, promote(self.globals)) machine.push(message) machine.push(ej) machine.run() return machine.pop()