Skip to content

Commit

Permalink
wmlscope: slightly improved percentage output when checking for untyp…
Browse files Browse the repository at this point in the history
…ed formals
  • Loading branch information
Elvish-Hunter committed Aug 6, 2015
1 parent 63863d9 commit 2559f97
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions data/tools/wmlscope
Expand Up @@ -257,13 +257,13 @@ sudo apt-get install python-pil""", file=sys.stderr)
unchecked.append((name, defn))
unresolvedcount += len(defn.references)
if unchecked:
print("# %d of %d (%d%%) macro definitions and %d of %d calls (%d%%) have untyped formals:" \
print("# %d of %d (%.02f%%) macro definitions and %d of %d calls (%.02f%%) have untyped formals:" \
% (len(unchecked),
defcount,
int((100 * len(unchecked)) / defcount),
((100 * len(unchecked)) / defcount),
unresolvedcount,
callcount,
int((100 * unresolvedcount) / callcount)))
((100 * unresolvedcount) / callcount)))
# sort by checking the 2nd element in the tuple
unchecked.sort(key=lambda element: element[1])
for (name, defn) in unchecked:
Expand Down

0 comments on commit 2559f97

Please sign in to comment.