@@ -2,6 +2,7 @@ private import codeql.ruby.AST
22private import codeql.ruby.controlflow.ControlFlowGraph
33private import internal.AST
44private import internal.TreeSitter
5+ private import internal.Method
56
67/** A callable. */
78class Callable extends StmtSequence , Expr , Scope , TCallable {
@@ -182,6 +183,8 @@ class Block extends Callable, StmtSequence, Scope, TBlock {
182183 or
183184 result = StmtSequence .super .getAChild ( pred )
184185 }
186+
187+ override string getAPrimaryQlClass ( ) { result = "Block" }
185188}
186189
187190/** A block enclosed within `do` and `end`. */
@@ -226,22 +229,3 @@ class BraceBlock extends Block, TBraceBlock {
226229
227230 final override string getAPrimaryQlClass ( ) { result = "BraceBlock" }
228231}
229-
230- /**
231- * A synthesized block, such as the block synthesized from the body of
232- * a `for` loop.
233- */
234- class SynthBlock extends Block , TBlockSynth {
235- SynthBlock ( ) { this = TBlockSynth ( _, _) }
236-
237- final override Parameter getParameter ( int n ) { synthChild ( this , n , result ) }
238-
239- final override Stmt getStmt ( int i ) {
240- i >= 0 and
241- synthChild ( this , i + this .getNumberOfParameters ( ) , result )
242- }
243-
244- final override string toString ( ) { result = "{ ... }" }
245-
246- final override string getAPrimaryQlClass ( ) { result = "SynthBlock" }
247- }
0 commit comments