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: levelheight Message-ID: <6879@watdaisy.UUCP> Date: Thu, 24-Jan-85 14:19:58 EST Article-I.D.: watdaisy.6879 Posted: Thu Jan 24 14:19:58 1985 Date-Received: Fri, 25-Jan-85 05:26:27 EST References: <2340@hplabsc.UUCP> <4948@utzoo.UUCP> <6292@boring.UUCP> <354@topaz.ARPA> <256@gumby.UUCP> Organization: U of Waterloo, Ontario Lines: 39 > 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)? > Dan Frank Theoretically, one could declare a record with a gigantic variant part, which sets the size of an array component for every integer in some sub-range. Theoretically, one could write a procedure that could do matrix operations on different-sized matrices when called by different calling statements (or by two executions of the same calling statement). However, PRACTICALLY speaking .... This is answer #1 to the above question. 2. I predict that Ada's feature will be grossly abused, where the programmer can specify the underlying values to be used in an enumerated type. Nonetheless, there are occasional valid needs for such a feature. 3. Passing portions of arrays as procedure parameters. That's a big reason that there is still no substitute for Fortran, even for some new code. 4. Arrays of procedure names / function names. C can simulate these with function pointers. (Ada has it for tasks, but that's not the same thing and can only provide an expensive simulation for it.) I'm sure there's more. However, if one needs to do such things, there are still benefits to debugging a Pascal program that does most of what's needed, before turning to other languages. -- 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."