[clang] [Clang][Interp] Fix display of syntactically-invalid note for member function calls (PR #102170)
Timm Baeder via cfe-commits
cfe-commits at lists.llvm.org
Wed Aug 7 07:51:28 PDT 2024
================
@@ -198,11 +198,11 @@ def NoRet : Opcode {}
def Call : Opcode {
- let Args = [ArgFunction, ArgUint32];
+ let Args = [ArgFunction, ArgUint32, ArgExpr];
----------------
tbaederr wrote:
Can we not get by without this? When emitting the diagnostic, the `CallExpr` should be on the caller frame, at the current frame's `RetPC`. We do something similar in `cleanupAfterFunctionCall`:
```c++
const Expr *CallSite = S.Current->Caller->getExpr(S.Current->getRetPC());
```
or is the problem that the expr we get here might not be a `CallExpr`, but e.g. a `CXXConstructExpr`?
https://github.com/llvm/llvm-project/pull/102170
More information about the cfe-commits
mailing list