jlg@lanl.ARPA (01/23/85)
> 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
robert@gitpyr.UUCP (Robert Viduya) (01/25/85)
> < > 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. > It's been a while since I checked, but doesn't the ISO standard for Pascal support the 'extern' or 'external' keyword? Being able to declare a procedure or function as external is just about all you need for seperate compilation. Granted, STANDARD Pascal doesn't support it. robert -- Robert Viduya Office of Computing Services Georgia Institute of Technology, Atlanta GA 30332 Phone: (404) 894-4669 ...!{akgua,allegra,amd,hplabs,ihnp4,masscomp,ut-ngp}!gatech!gitpyr!robert ...!{rlgvax,sb1,uf-cgrl,unmvax,ut-sally}!gatech!gitpyr!robert
steven@boring.UUCP (01/26/85)
In article <20081@lanl.ARPA> jlg@lanl.ARPA writes: > 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. This is a property of the implementation, rather than the language. It is perfectly possible, without altering the language, to separately compile Pascal procedures, and to have libraries of procedures, without jeopardising strong-typing. > In Pascal all actual array parameters must have the same size as the > formal array parameter was declared in the proceedure. [...] ISO Pascal and > Ada both have ways around this problem. So, Pascal both does and doesn't have this problem! Presumably what is meant is that it used to have this problem, but it's been fixed now (C used not to have structures). Let's agree that whenever we talk about a language in net.lang, we mean the most recent version. Steven Pemberton, CWI, Amsterdam.
herbie@watdcsu.UUCP (Herb Chong [DCS]) (01/27/85)
In article <68@gitpyr.UUCP> robert@gitpyr.UUCP (Robert Viduya) writes: >It's been a while since I checked, but doesn't the ISO standard for Pascal >support the 'extern' or 'external' keyword? Being able to declare a procedure >or function as external is just about all you need for seperate compilation. ..... > robert It's not a part of the standard but is a recommended extension to the standard in Jensen and Wirth. Herb Chong... I'm user-friendly -- I don't byte, I nybble.... UUCP: {decvax|utzoo|ihnp4|allegra|clyde}!watmath!water!watdcsu!herbie CSNET: herbie%watdcsu@waterloo.csnet ARPA: herbie%watdcsu%waterloo.csnet@csnet-relay.arpa NETNORTH, BITNET, EARN: herbie@watdcs, herbie@watdcsu
keesan@bbncca.ARPA (Morris M. Keesan) (01/29/85)
------------------------------------------------------------------------------- I just couldn't let this piece of USA centrism go by unchallenged. In article <20456@lanl.ARPA>, J. Giles (jlg@lanl.ARPA) says, > . . . Pascal is a language that is described in the book > "PASCAL User Manual and Report" by Jensen and Wirth. If a feature or > capability is not in this book then it's not in the language. > . . . > . . . - 'the most recent version' of Pascal is not ISO > Pascal. The most recent version is whatever someone has recently written > that he has decided to call 'Pascal'. . . > . . . I think ANSI has a standards committee > working on Pascal. If this committee succeeds - then there will be a > 'Standard Pascal' which will be the appropriate version for net.lang to > discuss. Say what? Something defined by the International Standards Organization (ISO) is not a standard, but something defined by the American National Standards Institute (ANSI) will be? Perhaps if net.lang were usa.lang the above statement might hold some water, but in a newsgroup that jlg admits reaches "as far afield as Amsterdam" (and, I might add, even farther, e.g. Australia) this kind of assertion is astounding. -- Morris M. Keesan {decvax,linus,ihnp4,wivax,wjh12,ima}!bbncca!keesan keesan @ BBN-UNIX.ARPA
mauney@ncsu.UUCP (Jon Mauney) (01/30/85)
> I think ANSI has a standards committee > working on Pascal. If this committee succeeds - then there will be a > 'Standard Pascal' which will be the appropriate version for net.lang to > discuss. It is not clear why an ANSI definition would be 'Standard Pascal', but the ISO definition is not 'Standard Pascal'. -- *** REPLACE THIS LINE WITH A HOOK AND SINKER *** Jon Mauney mcnc!ncsu!mauney C.S. Dept, North Carolina State University
jlg@lanl.ARPA (02/01/85)
> So it is with Pascal: it has now been standardised, with the blessing of > Wirth. It replaces Jensen and Wirth version. > > ISO stands for International Standards Organisation. It is supported by most > major governments, including, unless I'm very wrong, the USA. If you want > code for any language to be portable, you use the standard. ISO Pascal is > such a standard. J&W Pascal is dead. Once again! If any of the software vendors used the ISO standard (I know of only one that does) I would agree with all of the above. It doesn't matter what the acranym stands for or how many governments rubber stamped it - it only matters what is available in the marketplace. J&W Pascal is the ONLY Pascal that is even remotely portable (and someone pointed out that there are implementations of 'Pascal' that don't even meet J&W standards). Everyone agrees that the new Fortran standard is what is meant by Fortran because all the vendors use it. It is almost impossible to find a vendor of a Fortran compiler who doesn't at least CLAIM to be compatible with ANSI X3.0-1978 (or at least the subset). If the same were true of ISO Pascal we could all agree that it was now the REAL Pascal. J. Giles P.S. I have been informed that there IS an ANSI standard for Pascal. Since no one follows it either, this puts an end to my speculation that ANSI might be a more widely influential body.