diff options
Diffstat (limited to 'Lib/test/test_itertools.py')
-rw-r--r-- | Lib/test/test_itertools.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/test/test_itertools.py b/Lib/test/test_itertools.py index 0f1f695..a45e608 100644 --- a/Lib/test/test_itertools.py +++ b/Lib/test/test_itertools.py @@ -1268,6 +1268,8 @@ Samuele ... "combinations_with_replacement('ABC', 3) --> AA AB AC BB BC CC" ... pool = tuple(iterable) ... n = len(pool) +... if not n and r: +... return ... indices = [0] * r ... yield tuple(pool[i] for i in indices) ... while 1: |