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

           Summary: using __attribute__ on local variables does not generate
                    an error.
           Product: clang
           Version: trunk
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: parser
        AssignedTo: [email protected]
        ReportedBy: [email protected]
                CC: [email protected]


# 1 "/tmp/b.c"
# 1 "/tmp/b.c" 1
# 1 "<built-in>" 1
# 1 "<built-in>" 3
# 88 "<built-in>" 3
# 88 "<command line>" 1
# 1 "/tmp/b.c" 2
__attribute__((section("NEAR"))) int a1=0Xffff;
volatile char pt1;



int main()
{
 __attribute__((section("NEAR"))) int n1;
 a1=0xFFFF;
 if (a1=0XFFFF)
 n1=0x00FF;

}




$ gcc -c b.i
line-map.c: file "/tmp/b.c" left but not entered
In file included from /tmp/b.c:2,
                 from /tmp/b.c:2:
<built-in>: In function ‘main’:

<built-in>:96: error: section attribute cannot be specified for local variables


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