Files
codeql-lab/codeql-custom-queries-ruby/example.ql
2021-11-06 18:20:53 +08:00

12 lines
204 B
Plaintext

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