diff options
author | Damien George <damien.p.george@gmail.com> | 2014-02-12 23:02:49 +0000 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2014-02-12 23:02:49 +0000 |
commit | a8d404e0e1cfc3ad1fb171b5515f2685af4ffeca (patch) | |
tree | 59cb5ce2c2498b9f3aa19927eb513221b3622af3 /tests/basics/exec1.py | |
parent | 099a9cb575b254dd9e00fd1c60859aec7299deb7 (diff) | |
parent | 2aa217b97473932e1b49b5332942f4aaf74e7a34 (diff) | |
download | micropython-a8d404e0e1cfc3ad1fb171b5515f2685af4ffeca.tar.gz micropython-a8d404e0e1cfc3ad1fb171b5515f2685af4ffeca.zip |
Merge branch 'master' of github.com:micropython/micropython
Diffstat (limited to 'tests/basics/exec1.py')
-rw-r--r-- | tests/basics/exec1.py | 6 |
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"]()) |