[PATCH] D46958: [ASTImporter] Fix missing implict CXXRecordDecl
Gabor Marton via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu May 17 02:26:33 PDT 2018
martong added a comment.
In https://reviews.llvm.org/D46958#1101570, @a.sidorin wrote:
> So, we fail to add injected name to a CXXRecordDecl that has a described class template?
Yes, we failed to import the implicit `CXXRecordDecl`.
Here is how it looked before the fix:
From:
ClassTemplateDecl 0xecae28 <input.cc:2:7, line:4:7> line:3:14 declToImport
|-TemplateTypeParmDecl 0xecacd8 <line:2:17, col:26> col:26 typename depth 0 index 0 U
`-CXXRecordDecl 0xecad90 <line:3:7, line:4:7> line:3:14 struct declToImport definition
|-DefinitionData empty aggregate standard_layout trivially_copyable pod trivial literal has_constexpr_non_copy_move_ctor can_const_default_init
| |-DefaultConstructor exists trivial constexpr needs_implicit defaulted_is_constexpr
| |-CopyConstructor simple trivial has_const_param needs_implicit implicit_has_const_param
| |-MoveConstructor exists simple trivial needs_implicit
| |-CopyAssignment trivial has_const_param needs_implicit implicit_has_const_param
| |-MoveAssignment exists simple trivial needs_implicit
| `-Destructor simple irrelevant trivial needs_implicit
`-CXXRecordDecl 0xecb0a0 <col:7, col:14> col:14 implicit struct declToImport
To:
ClassTemplateDecl 0xf97cb0 <input.cc:2:7, line:3:14> col:14 declToImport
|-TemplateTypeParmDecl 0xf97c00 <line:2:17, col:26> col:26 typename depth 0 index 0 U
`-CXXRecordDecl 0xf97a48 <line:3:7, col:14> col:14 struct declToImport definition
`-DefinitionData pass_in_registers empty aggregate standard_layout trivially_copyable pod trivial literal has_constexpr_non_copy_move_ctor can_const_default_init
|-DefaultConstructor exists trivial constexpr needs_implicit defaulted_is_constexpr
|-CopyConstructor simple trivial has_const_param needs_implicit implicit_has_const_param
|-MoveConstructor exists simple trivial needs_implicit
|-CopyAssignment trivial has_const_param needs_implicit implicit_has_const_param
|-MoveAssignment exists simple trivial needs_implicit
`-Destructor simple irrelevant trivial needs_implicit
Thanks for the review.
Repository:
rC Clang
https://reviews.llvm.org/D46958
More information about the cfe-commits
mailing list