mirror of
https://github.com/github/codeql.git
synced 2025-12-21 11:16:30 +01:00
C++: Restrict the side effect of StoreChainEndInstructionSideEffect to be WriteSideEffectInstructions
This commit is contained in:
@@ -435,13 +435,13 @@ private Instruction skipConversion(Instruction instr) {
|
|||||||
* before entering `setter`.
|
* before entering `setter`.
|
||||||
*/
|
*/
|
||||||
private class StoreChainEndInstructionSideEffect extends StoreChainEndInstruction, ChiInstruction {
|
private class StoreChainEndInstructionSideEffect extends StoreChainEndInstruction, ChiInstruction {
|
||||||
SideEffectInstruction sideEffect;
|
WriteSideEffectInstruction sideEffect;
|
||||||
FieldAddressInstruction fi;
|
FieldAddressInstruction fi;
|
||||||
|
|
||||||
StoreChainEndInstructionSideEffect() {
|
StoreChainEndInstructionSideEffect() {
|
||||||
not this.isResultConflated() and
|
not this.isResultConflated() and
|
||||||
this.getPartial() = sideEffect and
|
this.getPartial() = sideEffect and
|
||||||
fi = skipConversion*(sideEffect.getAnOperand().getDef())
|
fi = skipConversion*(sideEffect.getArgumentDef())
|
||||||
}
|
}
|
||||||
|
|
||||||
override FieldAddressInstruction getFieldInstruction() { result = fi }
|
override FieldAddressInstruction getFieldInstruction() { result = fi }
|
||||||
|
|||||||
Reference in New Issue
Block a user