[PATCH] D46929: Fix a mangling failure on clang-cl C++17

Taiju Tsuiki via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed May 16 23:00:41 PDT 2018


tzik added a comment.

In https://reviews.llvm.org/D46929#1101780, @rnk wrote:

> I searched around, and I noticed that `VTableContext::getMethodVTableIndex` has the same implied contract that the caller must always provide a canonical declaration or things will break. It looks like it has three callers, and they all do this. We should probably sink the canonicalization into this helper as well and clean up the now-superfluous canonicalizations at the call site.


Updated.
As I'm not sure if it's safe to use non-canonicalized CXXMethodDecl for EmitVirtualMemPtrThunk and CGCall, I left using the canonical decl.
For other part, non-canonical decl looks working fine to me.


Repository:
  rC Clang

https://reviews.llvm.org/D46929





More information about the cfe-commits mailing list