http://llvm.org/bugs/show_bug.cgi?id=13592

             Bug #: 13592
           Summary: std::is_convertible is incorrect for abstract type
           Product: libc++
           Version: unspecified
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: All Bugs
        AssignedTo: [email protected]
        ReportedBy: [email protected]
                CC: [email protected]
    Classification: Unclassified


Created attachment 9042
  --> http://llvm.org/bugs/attachment.cgi?id=9042
Fixing is_convertible for abstract target types

`std::is_convertible<From, To>` should return false_type when `To` is an
abstract type. 
However, for example, 

    struct abstract
    {
        virtual int f() = 0;
    };

`std::is_convertible<abstract, abstract>` returns true_type. 
This is because clang's __is_convertible_to intrinsic ignores the abstractness
(I filed PR13591 for clang). 

Trivial patch attached.

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to