D7380: encoding: define per-use identity functions only in typechecking mode
yuja (Yuya Nishihara)
phabricator at mercurial-scm.org
Thu Nov 14 14:31:42 UTC 2019
yuja added a comment.
> strtolocal = pycompat.identity # type: (str) -> bytes
> strfromlocal = pycompat.identity # type: (bytes) -> str
`# type: Callable[[str], bytes]` might work. pytype complained
`# type: ... -> ...` is an invalid type comment.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST ACTION
https://phab.mercurial-scm.org/D7380/new/
REVISION DETAIL
https://phab.mercurial-scm.org/D7380
To: durin42, #hg-reviewers
Cc: yuja, dlax, mercurial-devel
More information about the Mercurial-devel
mailing list