[LLVMbugs] [Bug 11968] New: clang++ fails on ?: operator with bit fields in struct

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Feb 9 22:20:27 PST 2012


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

             Bug #: 11968
           Summary: clang++ fails on ?: operator with bit fields in struct
           Product: new-bugs
           Version: 3.0
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: llvm.20.dufflebunk at spamgourmet.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified


Created attachment 8030
  --> http://llvm.org/bugs/attachment.cgi?id=8030
Fails to compile

The attached short test case compiles without error with g++, but fails with
clang++. 

clang++ -o test.o -c test.cpp -v
clang version 3.0 (tags/RELEASE_30/final)
Target: x86_64-unknown-linux-gnu
Thread model: posix
 "/home/pmahon/opt/llvm-3.0/bin/clang" -cc1 -triple x86_64-unknown-linux-gnu
-emit-obj -mrelax-all -disable-free -disable-llvm-verifier -main-file-name
test.cpp -mrelocation-model static -mdisable-fp-elim -masm-verbose
-mconstructor-aliases -munwind-tables -target-cpu x86-64 -target-linker-version
2.21.53.20110810 -momit-leaf-frame-pointer -v -coverage-file test.o
-resource-dir /home/pmahon/opt/llvm-3.0/bin/../lib/clang/3.0
-fmodule-cache-path /var/tmp/clang-module-cache -internal-isystem
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../include/c++/4.6 -internal-isystem
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../include/c++/4.6/x86_64-linux-gnu
-internal-isystem
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../include/c++/4.6/backward
-internal-isystem /usr/local/include -internal-isystem
/home/pmahon/opt/llvm-3.0/bin/../lib/clang/3.0/include
-internal-externc-isystem /usr/include/x86_64-linux-gnu
-internal-externc-isystem /usr/include -fdeprecated-macro -ferror-limit 19
-fmessage-length 210 -fgnu-runtime -fobjc-runtime-has-arc
-fobjc-runtime-has-weak -fobjc-fragile-abi -fcxx-exceptions -fexceptions
-fdiagnostics-show-option -fcolor-diagnostics -o test.o -x c++ test.cpp
clang -cc1 version 3.0 based upon llvm 3.0 hosted on x86_64-unknown-linux-gnu
#include "..." search starts here:
#include <...> search starts here:
 /usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../include/c++/4.6
 /usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../include/c++/4.6/x86_64-linux-gnu
 /usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../include/c++/4.6/backward
 /usr/local/include
 /home/pmahon/opt/llvm-3.0/bin/../lib/clang/3.0/include
 /usr/include/x86_64-linux-gnu
 /usr/include
End of search list.
test.cpp:28:3: error: cannot compile this conditional operator yet
  (a==0) ? (b->C |= (d) ? 0 : 1) : (b->D |= (d) ? 0 : 1);
  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.

-- 
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.



More information about the llvm-bugs mailing list