]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
Use names SEEK_SET, etc instead of magic number (GH-12057)
authorngie-eign <1574099+ngie-eign@users.noreply.github.com>
Sun, 3 Mar 2019 07:28:26 +0000 (23:28 -0800)
committerInada Naoki <songofacandy@gmail.com>
Sun, 3 Mar 2019 07:28:26 +0000 (16:28 +0900)
commit848037c1476ddf86dd2798fca35527a63c764a8a
tree3db7ffcabbc9549e0db1669d4d0f37a9c19dd847
parent8589f14bbe55fb1ff5c765af5281100c38f0df63
Use names SEEK_SET, etc instead of magic number (GH-12057)

The previous code hardcoded `SEEK_SET`, etc. While it's very unlikely
that these values will change, it's best to use the definitions to avoid
there being mismatches in behavior with the code in the future.

Signed-off-by: Enji Cooper <yaneurabeya@gmail.com>
Lib/_pyio.py
Modules/_io/textio.c