Skip to content

Commit 8bab47b

Browse files
author
Guido van Rossum
committed
Update docstrings/comments in response to review.
1 parent fc2f577 commit 8bab47b

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

mypy/build.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1718,8 +1718,8 @@ def order_ascc(graph: Graph, ascc: AbstractSet[str], pri_max: int = PRI_ALL) ->
17181718
each SCC thus found. The recursion is bounded because at each
17191719
recursion the spread in priorities is (at least) one less.
17201720
1721-
In practice there are only a few priority levels (currently
1722-
N=3) and in the worst case we just carry out the same algorithm
1721+
In practice there are only a few priority levels (less than a
1722+
dozen) and in the worst case we just carry out the same algorithm
17231723
for finding SCCs N times. Thus the complexity is no worse than
17241724
the complexity of the original SCC-finding algorithm -- see
17251725
strongly_connected_components() below for a reference.

mypy/semanal.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3093,11 +3093,11 @@ def infer_reachability_of_if_statement(s: IfStmt,
30933093
for i in range(len(s.expr)):
30943094
result = infer_if_condition_value(s.expr[i], pyversion, platform)
30953095
if result in (ALWAYS_FALSE, MYPY_FALSE):
3096-
# The condition is always false, so we skip the if/elif body.
3096+
# The condition is considered always false, so we skip the if/elif body.
30973097
mark_block_unreachable(s.body[i])
30983098
elif result in (ALWAYS_TRUE, MYPY_TRUE):
3099-
# This condition is always true, so all of the remaining
3100-
# elif/else bodies will never be executed.
3099+
# This condition is considered always true, so all of the remaining
3100+
# elif/else bodies should not be checked.
31013101
if result == MYPY_TRUE:
31023102
# This condition is false at runtime; this will affect
31033103
# import priorities.

0 commit comments

Comments
 (0)