Closed
Description
Bugzilla Link | 16138 |
Resolution | FIXED |
Resolved on | May 31, 2013 11:58 |
Version | unspecified |
OS | Linux |
Reporter | LLVM Bugzilla Contributor |
CC | @d0k |
Extended Description
When I use clang to compile this file:
#include <stdio.h>
int index; // this is the line causing problem.
int main(int argc, char **argv)
{
puts("hello");
return 0;
}
I got the error: redefinition of 'index' as different kind of symbol.
It turns out that index
is one deprecated one function in posix.
Using gcc -std=c99
fixes the problem, but clang -std=c99
doesn't do the trick.
Is this because index()
is still defined in c99?