Mercurial > public > mercurial-scm > hg
comparison mercurial/posix.py @ 32291:bd872f64a8ba
cleanup: use set literals
We no longer support Python 2.6, so we can now use set literals.
author | Martin von Zweigbergk <martinvonz@google.com> |
---|---|
date | Fri, 10 Feb 2017 16:56:29 -0800 |
parents | f0ea0f642627 |
children | 38a2b9d90131 |
comparison
equal
deleted
inserted
replaced
32290:2959c3e986e0 | 32291:bd872f64a8ba |
---|---|
472 return None | 472 return None |
473 | 473 |
474 def setsignalhandler(): | 474 def setsignalhandler(): |
475 pass | 475 pass |
476 | 476 |
477 _wantedkinds = set([stat.S_IFREG, stat.S_IFLNK]) | 477 _wantedkinds = {stat.S_IFREG, stat.S_IFLNK} |
478 | 478 |
479 def statfiles(files): | 479 def statfiles(files): |
480 '''Stat each file in files. Yield each stat, or None if a file does not | 480 '''Stat each file in files. Yield each stat, or None if a file does not |
481 exist or has a type we don't care about.''' | 481 exist or has a type we don't care about.''' |
482 lstat = os.lstat | 482 lstat = os.lstat |