Skip to content

Commit

Permalink
[clang][Interp][NFC] Use GetPtrThisField intead of two ops
Browse files Browse the repository at this point in the history
  • Loading branch information
tbaederr committed Sep 24, 2023
1 parent 534c096 commit 3935a18
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions clang/lib/AST/Interp/ByteCodeStmtGen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -171,10 +171,7 @@ bool ByteCodeStmtGen<Emitter>::visitFunc(const FunctionDecl *F) {
} else {
// Non-primitive case. Get a pointer to the field-to-initialize
// on the stack and call visitInitialzer() for it.
if (!this->emitThis(InitExpr))
return false;

if (!this->emitGetPtrField(F->Offset, InitExpr))
if (!this->emitGetPtrThisField(F->Offset, InitExpr))
return false;

if (!this->visitInitializer(InitExpr))
Expand Down

0 comments on commit 3935a18

Please sign in to comment.