diff options
| author | Ezio Melotti <ezio.melotti@gmail.com> | 2009-06-27 23:45:39 (GMT) | 
|---|---|---|
| committer | Ezio Melotti <ezio.melotti@gmail.com> | 2009-06-27 23:45:39 (GMT) | 
| commit | 1dfd5d9f788ed39d558a88f1a3b883baf9c512ef (patch) | |
| tree | f4e47fdf7197d389a4bdf4cb2eb3ea45d46ee2af | |
| parent | 00a58c35748cb0da5d60385158766c79491d8225 (diff) | |
| download | cpython-1dfd5d9f788ed39d558a88f1a3b883baf9c512ef.zip cpython-1dfd5d9f788ed39d558a88f1a3b883baf9c512ef.tar.gz cpython-1dfd5d9f788ed39d558a88f1a3b883baf9c512ef.tar.bz2 | |
stmt and setup can contain multiple statements, see #5896
| -rw-r--r-- | Doc/library/timeit.rst | 5 | 
1 files changed, 3 insertions, 2 deletions
| diff --git a/Doc/library/timeit.rst b/Doc/library/timeit.rst index c545b97..fde1078 100644 --- a/Doc/library/timeit.rst +++ b/Doc/library/timeit.rst @@ -26,8 +26,9 @@ The module defines the following public class:     The constructor takes a statement to be timed, an additional statement used for     setup, and a timer function.  Both statements default to ``'pass'``; the timer -   function is platform-dependent (see the module doc string).  The statements may -   contain newlines, as long as they don't contain multi-line string literals. +   function is platform-dependent (see the module doc string).  *stmt* and *setup* +   may also contain multiple statements separated by ``;`` or newlines, as long as +   they don’t contain multi-line string literals.     To measure the execution time of the first statement, use the :meth:`timeit`     method.  The :meth:`repeat` method is a convenience to call :meth:`timeit` | 
