ABataev added a comment. In D71241#1787265 <https://reviews.llvm.org/D71241#1787265>, @hfinkel wrote:
> In D71241#1786959 <https://reviews.llvm.org/D71241#1786959>, @jdoerfert wrote: > > > In D71241#1786530 <https://reviews.llvm.org/D71241#1786530>, @ABataev wrote: > > > > > Most probably, we can use this solution without adding a new expression. > > > `DeclRefExpr` class can contain 2 decls: FoundDecl and the Decl being > > > used. You can use FoundDecl to point to the original function and used > > > decl to point to the function being called in this context. But at first, > > > we need to be sure that we can handle all corner cases correctly. > > > > > > What new expression are you talking about? > > > To be clear, I believe he's talking about the new expression that I proposed > we add in order to represent this kind of call. If that's not needed, and we > can use the FoundDecl/Decl pair for that purpose, that should also be > considered. > > > This solution already does point to both declarations, as shown here: > > https://reviews.llvm.org/D71241#1782504 Exactly. We need to check if the `MemberRefExpr` can do this too to handle member functions correctly. And need to wait for opinion from Richard Smith about the design. We need to be sure that it won't break compatibility with C/C++ in some corner cases. Design bugs are very hard to solve and I want to be sure that we don't miss anything. And we provide full compatibility with both C and C++. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71241/new/ https://reviews.llvm.org/D71241 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits