diff options
Diffstat (limited to 'tests/basics/fun-callstar.py')
-rw-r--r-- | tests/basics/fun-callstar.py | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/basics/fun-callstar.py b/tests/basics/fun-callstar.py new file mode 100644 index 0000000000..49b40d9594 --- /dev/null +++ b/tests/basics/fun-callstar.py @@ -0,0 +1,13 @@ +def foo(a, b, c): + print(a, b, c) + +foo(*(1, 2, 3)) +foo(1, *(2, 3)) +foo(1, 2, *(3,)) +foo(1, 2, 3, *()) + +# Another sequence type +foo(1, 2, *[100]) + +# Iterator +foo(*range(3)) |