Article View: comp.std.c
Article #1238Re: Small Language Wanted
From: Karl Heuer
Date: Tue, 01 Sep 1992 19:52
Date: Tue, 01 Sep 1992 19:52
34 lines
2243 bytes
2243 bytes
[I have removed comp.lang.fortran from the newsgroup list] In article <1992Sep1.130600.25488@siia.mv.com> drd@siia.mv.com (David Dick) writes: >In article <9224317.28165@mulga.cs.mu.OZ.AU> fjh@munta.cs.mu.OZ.AU (Fergus James HENDERSON) writes: >>Note that it makes sense to prevent users from redefining standard >>library functions, because doing so could have all sorts of undesireable >>side-effects. [Example deleted] > >The fact that programmers who know what they're doing could no longer >replace pieces of the libraries for debugging or *performance* reasons, >was apparently of no consequence. > >IMHO, the "safety" provided by this reservation is far outweighed by >the crippling of standard programming practice. The Standardization of C had absolutely no effect on this aspect of the language. In Classic C, if you override a library function by a user-written function of the same name, you get the expected results if you're "lucky", or if you know enough about the implementation details to understand that it's safe. The resulting program is not portable to an environment where the implementation details are different. In ANSI C, if you override a library function by a user-written function of the same name, you have violated a constraint; hence you get the expected results if you're "lucky", or if you know enough about the implementation details to understand that it's safe. The resulting program is not portable to an environment where the implementation details are different. The difference is that ANSI C explicitly documented something where Classic C programmers had to rely on common sense. Karl W. Z. Heuer (karl@ima.isc.com or uunet!ima!karl), The Walking Lint
Technical Details
Message-ID:
<1992Sep01.195232.4678@ima.isc.com>Path:
arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!think.com!spdcc!dirtydog.ima.isc.com!karlReferences:
<BURLEY.92Aug29143538@geech.gnu.ai.mit.edu> <9224317.28165@mulga.cs.mu.OZ.AU> <1992Sep1.130600.25488@siia.mv.com>Show Full Headers
Complete Article Headers
Newsgroups: comp.std.c Path: arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!think.com!spdcc!dirtydog.ima.isc.com!karl From: karl@ima.isc.com (Karl Heuer) Subject: Re: Small Language Wanted Message-ID: <1992Sep01.195232.4678@ima.isc.com> Sender: usenet@ima.isc.com (news) Organization: Interactive Systems, Cambridge, MA 02138-5302 References: <BURLEY.92Aug29143538@geech.gnu.ai.mit.edu> <9224317.28165@mulga.cs.mu.OZ.AU> <1992Sep1.130600.25488@siia.mv.com> Date: Tue, 01 Sep 1992 19:52:32 GMT Lines: 34