[llvm-bugs] [Bug 48307] New: struct DefinitionData &clang::CXXRecordDecl::data() const: Assertion `DD && "queried property of class with no definition"' failed

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Nov 25 23:16:08 PST 2020


https://bugs.llvm.org/show_bug.cgi?id=48307

            Bug ID: 48307
           Summary: struct DefinitionData &clang::CXXRecordDecl::data()
                    const: Assertion `DD && "queried property of class
                    with no definition"' failed
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: C++
          Assignee: unassignedclangbugs at nondot.org
          Reporter: chenyang at cs.utah.edu
                CC: blitzrakete at gmail.com, dgregor at apple.com,
                    erik.pilkington at gmail.com, llvm-bugs at lists.llvm.org,
                    richard-llvm at metafoo.co.uk

The following code triggered an assertion failure. It might be a dup of bug
12777.

$ cat foo.cc 
namespace NS  {
template<typename T> struct S {
  struct S1;
  struct S2;
  struct S3 : public S1, public S2 {};
};
}

$ clang -v
clang version 12.0.0 (https://github.com/llvm/llvm-project.git
75f50e15bf8fff6fba1d4678adedd33ef6a945e5)
Target: x86_64-unknown-linux-gnu
Thread model: posix

$ clang -c foo.cc 
clang:
/backup/work/compilers/compiler-source/llvm-project/clang/include/clang/AST/DeclCXX.h:434:
struct DefinitionData &clang::CXXRecordDecl::data() const: Assertion `DD &&
"queried property of class with no definition"' failed.
PLEASE submit a bug report to https://bugs.llvm.org/ and include the crash
backtrace, preprocessed source, and associated run script.
Stack dump:
0.      Program arguments:
/backup/work/compilers/compiler-install/llvm-12.0.0-dev/bin/clang -c foo.cc
1.      foo.cc:5:36: current parser token '{'
2.      foo.cc:1:1: parsing namespace 'NS'
3.      foo.cc:2:22: parsing struct/union/class body 'NS::S'
4.      foo.cc:5:3: parsing struct/union/class body 'NS::S::S3'
...

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20201126/33756094/attachment.html>


More information about the llvm-bugs mailing list