Files
codeql-lab/codeql-custom-queries-go/example.ql
2019-11-12 14:05:48 -08:00

13 lines
196 B
Plaintext

/**
* @name Empty block
* @kind problem
* @problem.severity warning
* @id go/example/empty-block
*/
import go
from BlockStmt b
where b.getNumStmt() = 0
select b, "This is an empty block."