Files
Aditya Sharad e2ab0b4faf Ruby: Fix compilation of example query
The AST library needs to be explicitly imported.
2022-11-02 17:56:36 -07:00

14 lines
229 B
Plaintext

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