mirror of
https://github.com/syssec-utd/pylingual.git
synced 2026-05-10 18:39:03 -07:00
ShortCircuitAnd adjustment
Was previously not matching
if a:
if b:
print(c)
which turned into
if a:
if b:
pass
print(c)
This commit is contained in:
committed by
Joel-Flores123
parent
d7ea284c29
commit
fab055f35f
@@ -127,7 +127,7 @@ class Assertion(ControlFlowTemplate):
|
||||
class ShortCircuitAnd(ControlFlowTemplate):
|
||||
template = T(
|
||||
A=~N("B", "tail"),
|
||||
B=~N("body", "tail").with_in_deg(1),
|
||||
B=~N("body", "tail").with_in_deg(1).with_cond(has_no_lines),
|
||||
body=~N.tail(),
|
||||
tail=N.tail(),
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user