Path: utzoo!news-server.csri.toronto.edu!cs.utexas.edu!uunet!ns-mx!ns-mx.uiowa.edu!rpruess From: rpruess@umaxc.weeg.uiowa.edu (Rex Pruess) Newsgroups: comp.sys.next Subject: Re: Library function redefinition Message-ID: Date: 4 Mar 91 20:13:20 GMT References: <1389@toaster.SFSU.EDU> <1396@toaster.SFSU.EDU> Sender: news@ns-mx.uiowa.edu Organization: U of Iowa, Iowa City, IA Lines: 39 In-reply-to: eps@toaster.SFSU.EDU's message of 4 Mar 91 09:06:55 GMT In many articles, eps@toaster.SFSU.EDU (Eric P. Scott) writes: > It's not a bug. It's a feature. Feature? No way. I, too, disagree with your opinion on shared libraries. Too many people are struggling with NeXT's implementation of shared libraries to consider it a feature. > Try reading someone else's code that's obfuscated things by redefining > common library procedures. I welcome the change! And I suppose being forced to rewrite someone else's code because they happened to have a conflict with a shared library name should be considered a feature. > What do you do about the case where procedures in the shared library > call other procedures in the shared library? Should they continue to > reference their shared library versions? Or yours? They should continue to reference their shared library versions. > If you opt for the former, you can no longer statically link. Correct. Static linking is not the answer. Variables in a program have local scope, followed by global scope. Apply the same logic to subroutine names. Resolve the local subroutine names before bringing in the shared library routines. > Refusing to link multiply-defined symbols keeps you out of trouble. > -=EPS=- Keeps me out of trouble? Tis not that simple. When NeXT Software Release 3.0, I'll be forced to sift through code to change routine names that clash with the new ones NeXT has decided to use. My crystal ball is not powerful enough to keep me out of "that" trouble. Now, can I take my phone out of the water? :-) -- Rex Pruess, Weeg Computing Center, Univ of Iowa, Iowa City, IA 52242 rpruess@umaxc.weeg.uiowa.edu (NeXTmail) (319) 335-5452