On Jan 24, 2011, at 1:30 PM, Renato Golin wrote: > On 24/01/11 17:33, Douglas Gregor wrote: >> That depends on the linker. With the Mac OS 10.6 dynamic linker, for >> example, a strong external symbol in one shared library will not get >> merged with same-named weak symbols in another shared library. > > Oh! I see... > > So what do you do? Mangle them differently? Or just make sure that > nothing in one object access the symbols in the other objects?
I believe the dynamic linker just assumes it never happens, and you get undefined behavior if it does. There really isn't much point in having a strong external symbol if everyone involved gives it weak semantics anyway. John. _______________________________________________ cfe-commits mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
