Commit 4e912c57 authored by Guido van Rossum's avatar Guido van Rossum

Don't use apply(), use f(foo, *args, *kwargs).

parent 9f75d6c6
...@@ -100,8 +100,7 @@ def handle_serials(oid, *args): ...@@ -100,8 +100,7 @@ def handle_serials(oid, *args):
A helper for function _handle_all_serials(). A helper for function _handle_all_serials().
""" """
args = (oid,) + args return handle_all_serials(oid, *args)[oid]
return apply(handle_all_serials, args)[oid]
def import_helper(name): def import_helper(name):
mod = __import__(name) mod = __import__(name)
......
...@@ -63,8 +63,7 @@ class SynchronizedStorage: ...@@ -63,8 +63,7 @@ class SynchronizedStorage:
## self.assertRaises(StorageTransactionError, callable *args) ## self.assertRaises(StorageTransactionError, callable *args)
def verifyNotCommitting(self, callable, *args): def verifyNotCommitting(self, callable, *args):
args = (StorageTransactionError, callable) + args self.assertRaises(StorageTransactionError, callable, *args)
apply(self.assertRaises, args)
def verifyWrongTrans(self, callable, *args): def verifyWrongTrans(self, callable, *args):
t = Transaction() t = Transaction()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment