Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site lanl.ARPA Path: utzoo!watmath!clyde!burl!ulysses!allegra!mit-eddie!godot!harvard!seismo!cmcl2!lanl!jlg From: jlg@lanl.ARPA Newsgroups: net.lang Subject: Re: Pascal typing Message-ID: <20081@lanl.ARPA> Date: Wed, 23-Jan-85 13:13:49 EST Article-I.D.: lanl.20081 Posted: Wed Jan 23 13:13:49 1985 Date-Received: Fri, 25-Jan-85 08:01:27 EST References: <2340@hplabsc.UUCP> <4948@utzoo.UUCP> <6292@boring.UUCP> <354@topaz.ARPA> <256@gumby.UUCP> Sender: newsreader@lanl.ARPA Organization: Los Alamos National Laboratory Lines: 28 > Can you give examples of things Pascal prevents you from doing, type-wise > (leave out decent i/o, casts and type conversions, stuff like that - we all > know that these are silly omissions from the language, and they ARE in > Modula-2)? Seperate compilation is restricted by Pascal since all proceedures used must be declared (and therefore present in their entirity) within the compilation unit that uses them. This restriction was explicitly for the purposes of strong typing (I believe they even discuss this in the Pascal 'User Manual and Report'). Ada corrects this problem by requiring only the specification of a proceedure to be present in the proceedure that uses it. In Pascal all actual array parameters must have the same size as the formal array parameter was declared in the proceedure. This means that general purpose matrix handlers, FFT's, etc. can't be written in pascal (or you must have a seperate copy for each size of array you wish to use in the present code). ISO Pascal and Ada both have ways around this problem. Pascal doesn't allow overloading of function names (not necessarily a disadvantage). Ada allows this to an unfortunate extreme (redefining operators such as '+' and '*' is a capability which causes no end to maintenance problems). There are other problems with Pascal typing, but this will already be enough to start lots of net arguments. J. Giles