gam@proper.UUCP (01/29/84)
> From: tjt@kobold.UUCP > > From: gam@proper.UUCP, Organization: Proper UNIX, San Leandro, CA > > > This is beginning to sound more like a problem of programmers' behavior > > than of any type-checking mechanism we might come up with. I think > > we should view this sort of type-checking as part of the programmer's > > job of creating `correct' code. > > If you want to view type-checking as part of the programmer's job, why > not include translating the program to assembly language or machine > language as part of the job also? Obviously translating the program to assembly language is part of the programmer's job, but fortunately we have compilers to do that (ah, *another* tool!). Thus should type-checking be part of the programmer's job, and he/she should use the tools (like lint) to do that. (It bothers me that some programmers have the attitude that if it gets past the compiler it must be OK. Sometimes the compiler DOESN'T produce the right code, so programmers should be aware of THAT, too!) > The basic premise of a high-level language is that a programmer is lazy > and incompetent.... Most people are too lazy perform that translation > [to assembly language] and are have great difficulty doing so without > errors. > > Similarly, strong type checking is nothing that cannot be done by the > programmer, by hand. Again, most programmers are too lazy to do this > checking by hand, and will generally make errors when doing so. And that is why I encourage the use of existing tools to avoid those errors. Again, there exist tools to do these things, I am just concerned that some programmers do not take their work seriously enough to use them. > Anyway, if you believe that strong type-checking is a valuable tool, > you should be willing to make it a standard part of your compiler... As has been stated here, there may be very good reasons (ie, kernel or device driver code) for types to be collided or abused. The programmer should not be a slave to the compiler's decisions; he/she is a thinking creature capable of judgement, and that judgement requires responsability. I cannot convince you (that is, `you guys') to be responsable programmers if you don't want to be. I can show you why it's important to do type-checking, and why it's important to write portable code, and why it's important to prove your code correct, but if you don't care, then all the tools in the world won't help. That is my point. -- Gordon A. Moffett { allegra, decvax!decwrl } !amd70!proper hplabs!intelca!proper!gam