[llvm-bugs] [Bug 27637] creating object of abstract class allowed in all versions of clang++

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Nov 16 13:00:23 PST 2020


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

Richard Smith <richard-llvm at metafoo.co.uk> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED
                 CC|                            |richard-llvm at metafoo.co.uk

--- Comment #2 from Richard Smith <richard-llvm at metafoo.co.uk> ---
This has been fixed; Clang now diagnoses:

<stdin>:12:14: error: allocating an object of abstract class type 'const A'
    const A& a{};
             ^
<stdin>:7:18: note: unimplemented pure virtual method 'b' in 'A'
    virtual void b() const = 0;
                 ^

-- 
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/20201116/eff8a064/attachment.html>


More information about the llvm-bugs mailing list