diff options
author | Andras Deak <deak.andris@gmail.com> | 2018-04-27 14:05:07 +0200 |
---|---|---|
committer | Andras Deak <deak.andris@gmail.com> | 2018-04-27 16:51:50 +0200 |
commit | 92f85239dad607540a1fa3124e41c7b357caf7fe (patch) | |
tree | 582f9f751e91b75e04f4d3a2cf4400d4a1ff8d27 /numpy/lib/function_base.py | |
parent | 79cd01d4e7daaf925d29194ce0cdfa7b14dba85c (diff) | |
download | numpy-92f85239dad607540a1fa3124e41c7b357caf7fe.tar.gz |
DOC: Make doc examples using StringIO python2-3 compatible
Diffstat (limited to 'numpy/lib/function_base.py')
-rw-r--r-- | numpy/lib/function_base.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/numpy/lib/function_base.py b/numpy/lib/function_base.py index 72beef471..a6e3e07d3 100644 --- a/numpy/lib/function_base.py +++ b/numpy/lib/function_base.py @@ -1633,9 +1633,9 @@ def disp(mesg, device=None, linefeed=True): Besides ``sys.stdout``, a file-like object can also be used as it has both required methods: - >>> from StringIO import StringIO + >>> from io import StringIO >>> buf = StringIO() - >>> np.disp('"Display" in a file', device=buf) + >>> np.disp(u'"Display" in a file', device=buf) >>> buf.getvalue() '"Display" in a file\\n' |