File tree Expand file tree Collapse file tree 3 files changed +7
-4
lines changed
cpp/ql/lib/semmle/code/cpp/ir/implementation Expand file tree Collapse file tree 3 files changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -247,8 +247,7 @@ class Instruction extends Construction::TStageInstruction {
247247 * Gets the type of the result produced by this instruction. If the instruction does not produce
248248 * a result, its result type will be `IRVoidType`.
249249 */
250- cached
251- final IRType getResultIRType ( ) { result = this .getResultLanguageType ( ) .getIRType ( ) }
250+ final IRType getResultIRType ( ) { result = Construction:: getInstructionResultIRType ( this ) }
252251
253252 /**
254253 * Gets the type of the result produced by this instruction. If the
Original file line number Diff line number Diff line change @@ -247,8 +247,7 @@ class Instruction extends Construction::TStageInstruction {
247247 * Gets the type of the result produced by this instruction. If the instruction does not produce
248248 * a result, its result type will be `IRVoidType`.
249249 */
250- cached
251- final IRType getResultIRType ( ) { result = this .getResultLanguageType ( ) .getIRType ( ) }
250+ final IRType getResultIRType ( ) { result = Construction:: getInstructionResultIRType ( this ) }
252251
253252 /**
254253 * Gets the type of the result produced by this instruction. If the
Original file line number Diff line number Diff line change @@ -429,6 +429,11 @@ private module Cached {
429429 instr = unreachedInstruction ( _) and result = Language:: getVoidType ( )
430430 }
431431
432+ cached
433+ IRType getInstructionResultIRType ( Instruction instr ) {
434+ result = instr .getResultLanguageType ( ) .getIRType ( )
435+ }
436+
432437 /**
433438 * Holds if `opcode` is the opcode that specifies the operation performed by `instr`.
434439 *
You can’t perform that action at this time.
0 commit comments