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

           Summary: clang rejects apparently valid code
           Product: clang
           Version: unspecified
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Semantic Analyzer
        AssignedTo: [email protected]
        ReportedBy: [email protected]
                CC: [email protected], [email protected]


This but was discovered trying to parse diffutils-2.8.1:

$ cat bug.c
struct re_pattern_buffer ignore_regexp;

struct re_pattern_buffer {
  unsigned char *buffer;
};
$ gcc -Wall -W -c  bug.c
$ icc -w2 -c bug.c
$ clang -w bug.c
bug.c:1:26: error: variable has incomplete type 'struct re_pattern_buffer'
struct re_pattern_buffer ignore_regexp;
                         ^
1 diagnostic generated.
$

This code parses OK also with the Comeau C compiler.


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