Merge pull request #376 from marcjansen/singular-plural

Use correct singular/plural of noun.
This commit is contained in:
Marc Jansen
2013-03-15 02:03:49 -07:00

View File

@@ -506,7 +506,9 @@ def find_fixme(t):
f.close()
for filename in matches:
print ' %s has %d matches:' % (filename, len(matches[filename]))
num_matches = len(matches[filename])
noun = 'matches' if num_matches > 1 else 'match'
print ' %s has %d %s:' % (filename, num_matches, noun)
for match in matches[filename]:
print ' %s' % (match,)
print