www.digitalmars.com         C & C++   DMDScript  

D.gnu - What exactly is 'one-only linkage'?

reply Drew McCormack <drewmccormack mac.com> writes:
I am getting a warning on Mac OS X about the system not supporting 
one-only linkage. I also see it in the known-issues on the web site. It 
has a work around, which I will try if I need to. But to know whether I 
need to, I need to know what one-only linkage is. Anyone?

Drew
May 04 2004
parent David Friedman <d3rdclsmail earthlink.net> writes:
Drew McCormack wrote:
 I am getting a warning on Mac OS X about the system not supporting 
 one-only linkage. I also see it in the known-issues on the web site. It 
 has a work around, which I will try if I need to. But to know whether I 
 need to, I need to know what one-only linkage is. Anyone?
 
 Drew
 
One-only linkage tells the linker to use only one instance of a function or a variable if it is defined multiple times (normally, this is an error.) If your program uses the same template instance in more than one module, you will probably need to use the work-around. If you see "multiple definitions" errors when linking, then you have to use it. David
May 04 2004