[LLVMbugs] [Bug 23072] New: Unjustified warning for D.3

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Mon Mar 30 09:55:47 PDT 2015


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

            Bug ID: 23072
           Summary: Unjustified warning for D.3
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++14
          Assignee: unassignedclangbugs at nondot.org
          Reporter: sasho648 at gmail.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

The problem is that an unjustified warning is arisen when explicitly defaulted
copy-constructor is defined when the class has a user-declared copy
assignment operator or a user-declared destructor. $D.3 states it's about
implicit and not explicit definition. Quote:

The implicit definition of a copy constructor as defaulted is deprecated if the
class has a user-declared copy
assignment operator or a user-declared destructor. 

Code like this:

struct W {

  W(const W&) = default;  

  int a;

  ~W() { a = 9; }
};

will emit unjustified warning for now.

-- 
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/20150330/278e1cd8/attachment.html>


More information about the llvm-bugs mailing list