[LLVMbugs] [Bug 5958] common symbol in "extern C" not generated

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Mon Apr 19 14:50:51 PDT 2010


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

Fariborz Jahanian <fjahanian at apple.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED

--- Comment #2 from Fariborz Jahanian <fjahanian at apple.com> 2010-04-19 16:50:50 CDT ---
It is not reproducible any more:
extern "C" {
int EXTERN_C_A;
int EXTERN_C_B = 4;
};

int foo(void) {
    return EXTERN_C_A;
}

int bar(void) {
    return EXTERN_C_B;
}

% clang -###
Apple clang version 1.5 (trunk 101769)
Target: x86_64-apple-darwin10
Thread model: posix
% clang -c test.cpp
[% nm -nm test.o | grep EXTERN
0000000000000034 (__DATA,__data) external _EXTERN_C_B
00000000000000b0 (__DATA,__common) external _EXTERN_C_A

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