From b40a0c18b142a33714fc9ba8205cb8da48403404 Mon Sep 17 00:00:00 2001 From: Benjamin Peterson Date: Tue, 23 Nov 2010 20:32:07 -0600 Subject: [PATCH] python3 fixes --- bench/bench.py | 2 +- bench/empty.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bench/bench.py b/bench/bench.py index 0a356a990..c9644ef61 100644 --- a/bench/bench.py +++ b/bench/bench.py @@ -7,4 +7,4 @@ if __name__ == '__main__': p = pstats.Stats("prof") p.strip_dirs() p.sort_stats('cumulative') - print p.print_stats(30) + print(p.print_stats(30)) diff --git a/bench/empty.py b/bench/empty.py index c9e2e6b5f..ac5e25701 100644 --- a/bench/empty.py +++ b/bench/empty.py @@ -1,3 +1,3 @@ - +import py for i in range(1000): - exec "def test_func_%d(): pass" % i + py.builtin.exec_("def test_func_%d(): pass" % i)