comparison mercurial/verify.py @ 7622:4dd7b28003d2

use dict.iteritems() rather than dict.items() This should be faster and more future-proof. Calls where the result is to be sorted using util.sort() have been left unchanged. Calls to .items() on configparser objects have been left as-is, too.
author Dirkjan Ochtman <dirkjan@ochtman.nl>
date Mon, 12 Jan 2009 09:16:03 +0100
parents 9fe97eea5510
children 43cfbb21f04d
comparison
equal deleted inserted replaced
7621:6d891df43a5f 7622:4dd7b28003d2
218 except Exception, inst: 218 except Exception, inst:
219 exc(lr, _("checking rename of %s") % short(n), inst, f) 219 exc(lr, _("checking rename of %s") % short(n), inst, f)
220 220
221 # cross-check 221 # cross-check
222 if f in filenodes: 222 if f in filenodes:
223 fns = [(mf.linkrev(l), n) for n,l in filenodes[f].items()] 223 fns = [(mf.linkrev(l), n) for n,l in filenodes[f].iteritems()]
224 for lr, node in util.sort(fns): 224 for lr, node in util.sort(fns):
225 err(lr, _("%s in manifests not found") % short(node), f) 225 err(lr, _("%s in manifests not found") % short(node), f)
226 226
227 for f in storefiles: 227 for f in storefiles:
228 warn(_("warning: orphan revlog '%s'") % f) 228 warn(_("warning: orphan revlog '%s'") % f)