[LLVMbugs] [Bug 17103] New: Invalid result of enum-type comparison

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Wed Sep 4 15:50:21 PDT 2013


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

            Bug ID: 17103
           Summary: Invalid result of enum-type comparison
           Product: clang
           Version: 3.2
          Hardware: Macintosh
                OS: MacOS X
            Status: NEW
          Severity: release blocker
          Priority: P
         Component: C++11
          Assignee: unassignedclangbugs at nondot.org
          Reporter: sizov at phys.ru
                CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
    Classification: Unclassified

#include <iostream>

enum struct foo_t : int32_t
{
    A = -1,
    C
};

int main()
{
    static_assert( foo_t::A < foo_t::C, "" ); // < --- ok
    std::cout << ( foo_t::A < foo_t::C ) << std::endl; // <--- print 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/20130904/f3dd72d8/attachment.html>


More information about the llvm-bugs mailing list