You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Clang] Do not attempt to access the DefinitionData of an incomplete type (#99998)
We were asserting here because we were trying to access the
`DefinitionData` of an incomplete type in the `Visit` lambda in
`CXXRecordDecl::hasSubobjectAtOffsetZeroOfEmptyBaseType`.
The code that creates `FieldDecl`s always marks them as invalid
if their type is incomplete, so checking whether the field decl
whose type we’re about to look at is invalid fixes this issue.
Fixes#99868.
Copy file name to clipboardExpand all lines: clang/test/CXX/temp/temp.arg/temp.arg.template/p3-0x.cpp
+10Lines changed: 10 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -38,3 +38,13 @@ X1<int, X1a> inst_x1a;
38
38
X1<long, X1b> inst_x1b;
39
39
X1<short, X1c> inst_x1c;
40
40
X1<short, X1d> inst_x1d; // expected-error{{template template argument has different template parameters than its corresponding template template paramete}}
41
+
42
+
template <int> classX2; // expected-note{{template is declared here}} \
0 commit comments