Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site watdaisy.UUCP Path: utzoo!watmath!watdaisy!ndiamond From: ndiamond@watdaisy.UUCP (Norman Diamond) Newsgroups: net.lang Subject: Re: "safety" of a language Message-ID: <6886@watdaisy.UUCP> Date: Mon, 28-Jan-85 12:06:18 EST Article-I.D.: watdaisy.6886 Posted: Mon Jan 28 12:06:18 1985 Date-Received: Tue, 29-Jan-85 05:43:05 EST References: <2340@hplabsc.UUCP> <4948@utzoo.UUCP> <6292@boring.UUCP> <1050@opus.UUCP> Organization: U of Waterloo, Ontario Lines: 25 > In Pascal, it's perfectly reasonable to change the type of a variable or > the parameters of a procedure, fix what you can find, and let the compiler > find the rest. In C, there's a big chance that there will be errors that > the compiler won't catch. Unfortunately, this is a poor example. With very rare exceptions, user-defined type names should be declared in both languages, and used consistently in each set of procedures. Of course, when two kinds of variables do not really represent the same kind of object, but only happen to be expressible using isomorphic types, they should still have two distinct type-names. Now, when you want to change the type of a variable and related parameters, etc., you change the type definition in one place, and the program remains consistent. In either language. Of course, C didn't used to support this possibility until enough Pascal users discovered how powerful a tool it was. -- Norman Diamond UUCP: {decvax|utzoo|ihnp4|allegra|clyde}!watmath!watdaisy!ndiamond CSNET: ndiamond%watdaisy@waterloo.csnet ARPA: ndiamond%watdaisy%waterloo.csnet@csnet-relay.arpa "Opinions are those of the keyboard, and do not reflect on me or higher-ups."