CodeQL library for Ruby
codeql/ruby-all 0.8.15-dev (changelog, source)
Search

Member predicate BasicBlock::immediatelyDominates

Holds if this basic block immediately dominates basic block bb.

That is, all paths reaching basic block bb from some entry point basic block must go through this basic block (which is an immediate predecessor of bb).

Example:

def m b
  if b
    return 0
  end
  return 1
end

The basic block starting on line 2 immediately dominates the basic block on line 5 (all paths from the entry point of m to return 1 must go through the if block).

predicate immediatelyDominates(BasicBlock bb)