Subject: Re: how to handle namespace cleanup
To: Chris G Demetriou <Chris_G_Demetriou@lagavulin.pdl.cs.cmu.edu>
From: Mark P. Gooderum <mark@nirvana.good.com>
List: tech-userlevel
Date: 12/08/1994 23:28:17
> I'd _much_ rather see 'real weak symbols' implemented properly.  The
> thought of renaming or shadowing a lot of files in libc is, IMNSHO, nasty.

I agree, after lots of developing on Solaris, I find times that I really
miss real weak symbols.  They are useful for some other things too.
It's nice to be able to "rip-off" standard calls but still access the 
original calls in a standard fashion.  I've used this to add reentrancy
support to library functions and system calls that don't have it in 
seriously signal abusing and threaded programs, or to work around 
broken commercial libraries that called things they shouldn't or badly.

Failing that, I'd prefer to see the one source file/#define trick
(or some other hack that didn't require N extra source files where N is
the number of functions, or at least files, already in a library).
Maybe a structured comment or special null macro that got extracted by
a rule to automatically generate the stub source so you didn't have to
completely wrap every function with an #ifdef/#endif wrapper
--
Mark Gooderum