Mercurial > hg
changeset 20681:52e5aca15f0c
webutil: move from dict() construction to {} literals
The latter are both faster and more consistent across Python 2 and 3.
author | Augie Fackler <raf@durin42.com> |
---|---|
date | Wed, 12 Mar 2014 13:20:04 -0400 |
parents | d3d3e94e2910 |
children | 7f8cbaaa8eea |
files | mercurial/hgweb/webutil.py |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/hgweb/webutil.py Wed Mar 12 13:19:43 2014 -0400 +++ b/mercurial/hgweb/webutil.py Wed Mar 12 13:20:04 2014 -0400 @@ -146,7 +146,7 @@ def renamelink(fctx): r = fctx.renamed() if r: - return [dict(file=r[0], node=hex(r[1]))] + return [{'file': r[0], 'node': hex(r[1])}] return [] def nodetagsdict(repo, node):