[llvm-bugs] [Bug 42829] New: Assertion `MaybeODRUseExprs.empty() && "Leftover expressions for odr-use checking"' failed (recent regression)

via llvm-bugs llvm-bugs at lists.llvm.org
Tue Jul 30 09:06:18 PDT 2019


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

            Bug ID: 42829
           Summary: Assertion `MaybeODRUseExprs.empty() && "Leftover
                    expressions for odr-use checking"' failed (recent
                    regression)
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
          Assignee: unassignedclangbugs at nondot.org
          Reporter: maltsevm at gmail.com
                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

Starting with:

commit 715f7a1bd058c64a39cc4773114dfb46ae8cc8a3
Author: Richard Smith <richard-llvm at metafoo.co.uk>
Date:   Tue Jun 11 17:50:32 2019 +0000

    For DR712: store on a DeclRefExpr whether it constitutes an odr-use.

    Begin restructuring to support the forms of non-odr-use reference
    permitted by DR712.

    llvm-svn: 363086

The following code causes an assertion failure:

$ cat test.cc
const unsigned long s = alignof(int);
void foo() {  alignas(s) int j; }

$ clang -fsyntax-only test.cc
... clang/lib/Sema/SemaDecl.cpp:13525: clang::Decl*
clang::Sema::ActOnFinishFunctionBody(clang::Decl*, clang::Stmt*, bool):
Assertion `MaybeODRUseExprs.empty() && "Leftover expressions for odr-use
checking"' failed.
...

-- 
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/20190730/f6bc58c1/attachment-0001.html>


More information about the llvm-bugs mailing list