Mercurial > public > mercurial-scm > hg
changeset 52575:f106d0e629e5
extensions: replace a trivial file read with the `util` function
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Tue, 17 Dec 2024 01:00:59 -0500 |
parents | cac851655570 |
children | 08612516d436 |
files | mercurial/extensions.py |
diffstat | 1 files changed, 1 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/extensions.py Tue Dec 17 00:56:01 2024 -0500 +++ b/mercurial/extensions.py Tue Dec 17 01:00:59 2024 -0500 @@ -885,8 +885,7 @@ This may raise IOError or SyntaxError. """ - with open(path, 'rb') as src: - root = ast.parse(src.read(), path) + root = ast.parse(util.readfile(path), path) cmdtable = {} # Python 3.12 started removing Bytes and Str and deprecate harder