Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!uwvax!umnd-cs!umn-cs!papowell From: papowell@umn-cs.UUCP (Patrick Powell) Newsgroups: comp.lang.c Subject: Creeping ADAisms in C Message-ID: <1535@umn-cs.UUCP> Date: Sun, 3-May-87 13:32:59 EDT Article-I.D.: umn-cs.1535 Posted: Sun May 3 13:32:59 1987 Date-Received: Mon, 4-May-87 01:36:29 EDT Organization: University of Minnesota, Minneapolis Lines: 37 Keywords: quit inventing jargon When the ADA language was engineered, the designers, with malice aforthought, decided to avoid using terms taken from other languages, for constructions that had slightly different semantics. The most glaring example is the use of "package" for the "module" type of construct. You can argue, I admit, that "packages" are an instantiation of a more general concept, and that "packages" don't have the same behaviour as "modules". However, I fail to see why they didn't call the "if-then-else" construct a condistat (following the same idea). I notice with amusement that the ANSI C people have been taken by the same bug. Lets look at "function prototypes". I will admit that using "function type declarations" will be anathema to some people, in that the idea that a function has a type will be very vulgar. What is the "type" of a function? Well, if we think about functions as "objects", then they can be classed as "control" objects, VS data, which has "data" objects. Now, the type of a function is the data type it will return (VOID if none), the number and type of its arguments (if any). Functions can be highly constrained types, with strict requirements about the number and type of arguements, or polymorphic, allowing a class of types on a parameters, or polygenic, with a variable number of arguments... But, by T'Great Thundering Bejaysus, a function has a type... Now we argue about control objects, and whether they are static or dynamically bound... A function prototype is a declaration of the TYPE of a function. So why not call it a function declaration, and the place where you define it, a function DEFINITION? Why introduce new jargon? Why confuse people by using the jargon when there is a perfectly acceptable existing phrase, currently available, and known to the practioners of the art, which is perfectly useful? A language definition is a continual search for a path between complexity and simplicity, and I think that people are getting a little too complex... -- Patrick Powell, Dept. Computer Science, 136 Lind Hall, 207 Church St. SE, University of Minnesota, Minneapolis, MN 55455 (612)625-3543/625-4002