[llvm-bugs] [Bug 31639] New: diagnose_if triggers an assertion failure when disabling a constructor.

via llvm-bugs llvm-bugs at lists.llvm.org
Fri Jan 13 16:08:30 PST 2017


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

            Bug ID: 31639
           Summary: diagnose_if triggers an assertion failure when
                    disabling a constructor.
           Product: clang
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
          Assignee: george.burgess.iv at gmail.com
          Reporter: george.burgess.iv at gmail.com
                CC: dgregor at apple.com, llvm-bugs at lists.llvm.org
    Classification: Unclassified

Repro:

struct Foo { Foo(int I) __attribute__((diagnose_if(I, "oh no", "error"))); };
void bar() { Foo f(1); }


Assertion: void clang::Sema::NoteDeletedFunction(clang::FunctionDecl *):
Assertion `Decl->isDeleted()' failed.

Nothing Bad Happens™ if we compile with a non-asserts build, but the
diagnostics are really unhelpful in that case.

-- 
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/20170114/8da17b69/attachment.html>


More information about the llvm-bugs mailing list