mirror of
https://github.com/github/codeql.git
synced 2025-12-25 21:26:37 +01:00
13 lines
406 B
Plaintext
13 lines
406 B
Plaintext
|
|
import python
|
|
|
|
import semmle.python.Pruning
|
|
|
|
from Pruner::UnprunedBasicBlock pred, Pruner::UnprunedBasicBlock succ, int line1, int line2
|
|
where Pruner::simplyDead(pred, succ) and
|
|
line1 = pred.last().getNode().getLocation().getStartLine() and
|
|
line2 = succ.first().getNode().getLocation().getStartLine() and
|
|
line1 > 0
|
|
select line1, pred.last().getNode().toString(), line2, succ.first().getNode().toString()
|
|
|