[LLVMbugs] [Bug 3418] New: Strange parse error with __extension__ operator

bugzilla-daemon at cs.uiuc.edu bugzilla-daemon at cs.uiuc.edu
Mon Jan 26 23:56:32 PST 2009


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

           Summary: Strange parse error with __extension__ operator
           Product: clang
           Version: unspecified
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: parser
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: sharparrow1 at yahoo.com
                CC: llvmbugs at cs.uiuc.edu


Testcase:
int a() {
  __extension__ (*(char*)0) = 1;
}

clang output:
<stdin>:2:29: error: expected ';' after expression
  __extension__ (*(char*)0) = 1;
                            ^
<stdin>:2:29: error: expected expression
<stdin>:2:3: warning: expression result unused
  __extension__ (*(char*)0) = 1;
  ^             ~~~~~~~~~~~
3 diagnostics generated.

gcc accepts this without any errors/warnings.


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