PEP-654: state that interior nodes are checked for match in subgroup/split (GH-2113)
This commit is contained in:
parent
859b31cd4a
commit
f991f604b6
|
@ -218,9 +218,13 @@ contains only those exceptions for which the condition is true:
|
|||
>>>
|
||||
|
||||
|
||||
The match condition is also applied to interior nodes (the exception
|
||||
groups), and a match causes the whole subtree rooted at this node
|
||||
to be included in the result.
|
||||
|
||||
Empty nested groups are omitted from the result, as in the
|
||||
case of ``ExceptionGroup("three")`` in the example above. If none of the
|
||||
leaf exceptions match the condition, ``subgroup`` returns ``None`` rather
|
||||
exceptions match the condition, ``subgroup`` returns ``None`` rather
|
||||
than an empty group. The original ``eg``
|
||||
is unchanged by ``subgroup``, but the value returned is not necessarily a full
|
||||
new copy. Leaf exceptions are not copied, nor are exception groups which are
|
||||
|
|
Loading…
Reference in New Issue