[PRL] Joel on Software - Making Wrong Code Look Wrong

Dave Herman dherman at ccs.neu.edu
Wed May 11 14:32:04 EDT 2005


> When you think of "type" as meaning "storage class", then I suppose Joel 
> is right to say that Simonyi is mistaken, and that the notation is not 
> for types.

I don't think that's necessarily what he meant. I think it was more that 
the type system gives you some fixed set of program properties, and 
duplicating those properties in naming conventions is not very helpful. 
But adding properties that are not expressible in the type system (e.g., 
szFoo is a char* serving as a zero-terminated string, or ixBar is an 
integer serving as an array index) is more useful.

> But if you think of "type" as "classification according to semantic 
> meaning", then it seems like Joel is dead wrong.  Simonyi was right to 
> call it a type, and all Simonyi was doing was making up for the 
> impoverished type meta language he had available.

Agreed. I disagree with Joel (or at least his implication) that 
Hungarian notation is the only solution available. As we've all noticed, 
what he's doing is largely repeating the (tedious, error-prone) work of 
a type system or flow analysis.

Dave



More information about the PRL mailing list