summaryrefslogtreecommitdiffstatshomepage
path: root/tests/basics
diff options
context:
space:
mode:
authorPaul Sokolovsky <pfalcon@users.sourceforge.net>2014-02-13 00:36:54 +0200
committerPaul Sokolovsky <pfalcon@users.sourceforge.net>2014-02-13 00:36:54 +0200
commit2aa217b97473932e1b49b5332942f4aaf74e7a34 (patch)
tree3b2ed54aeada6eb24db12d81c5503c57083aaef6 /tests/basics
parent780ba22bb8d4451761952a5401cb15935c8eb4fb (diff)
downloadmicropython-2aa217b97473932e1b49b5332942f4aaf74e7a34.tar.gz
micropython-2aa217b97473932e1b49b5332942f4aaf74e7a34.zip
Implement full arg handling for exec().
Diffstat (limited to 'tests/basics')
-rw-r--r--tests/basics/exec1.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/basics/exec1.py b/tests/basics/exec1.py
new file mode 100644
index 0000000000..59de5d69a2
--- /dev/null
+++ b/tests/basics/exec1.py
@@ -0,0 +1,6 @@
+print(exec("def foo(): return 42"))
+print(foo())
+
+d = {}
+exec("def bar(): return 84", d)
+print(d["bar"]())