We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 771abf4 commit 57cc316Copy full SHA for 57cc316
cpp/ql/lib/semmle/code/cpp/ir/implementation/aliased_ssa/IRBlock.qll
@@ -271,8 +271,9 @@ private module Cached {
271
/** Holds if `i` is the `index`th instruction in `block`. */
272
cached
273
Instruction getInstruction(TIRBlock block, int index) {
274
- exists(Instruction first |
275
- block = MkIRBlock(first) and
+ exists(Instruction first | block = MkIRBlock(first) |
+ first = result and index = 0
276
+ or
277
index = getMemberIndex(result) and
278
BlockAdjacency::getEquivalenceClass(first) = BlockAdjacency::getEquivalenceClass(result)
279
)
0 commit comments