Mercurial > hg
comparison mercurial/templatefilters.py @ 48932:176f1a0d15dc
py3: use int instead of pycompat.long
pycompat.long is aliased to int. So this should have no change in
functionality.
Differential Revision: https://phab.mercurial-scm.org/D12338
author | Gregory Szorc <gregory.szorc@gmail.com> |
---|---|
date | Tue, 01 Mar 2022 20:50:34 -0800 |
parents | f254fc73d956 |
children | 06de08b36c82 |
comparison
equal
deleted
inserted
replaced
48931:6f10a2d6adf9 | 48932:176f1a0d15dc |
---|---|
332 return b'null' | 332 return b'null' |
333 elif obj is False: | 333 elif obj is False: |
334 return b'false' | 334 return b'false' |
335 elif obj is True: | 335 elif obj is True: |
336 return b'true' | 336 return b'true' |
337 elif isinstance(obj, (int, pycompat.long, float)): | 337 elif isinstance(obj, (int, int, float)): |
338 return pycompat.bytestr(obj) | 338 return pycompat.bytestr(obj) |
339 elif isinstance(obj, bytes): | 339 elif isinstance(obj, bytes): |
340 return b'"%s"' % encoding.jsonescape(obj, paranoid=paranoid) | 340 return b'"%s"' % encoding.jsonescape(obj, paranoid=paranoid) |
341 elif isinstance(obj, type(u'')): | 341 elif isinstance(obj, type(u'')): |
342 raise error.ProgrammingError( | 342 raise error.ProgrammingError( |