Path: utzoo!attcan!uunet!ncrlnk!ncrcae!hubcap!gatech!ncsuvx!cscadm!mauney From: mauney@cscadm.ncsu.edu (Jon Mauney) Newsgroups: comp.lang.misc Subject: Re: Pascal Semicolons Message-ID: <2392@ncsuvx.ncsu.edu> Date: 15 Dec 88 14:47:27 GMT References: <1126@etive.ed.ac.uk> <208100002@s.cs.uiuc.edu> Sender: sam@ncsuvx.ncsu.edu Reply-To: mauney@cscadm.UUCP (Jon Mauney) Organization: Computer Science Faculty, NCSU, Raleigh NC Lines: 38 In article <208100002@s.cs.uiuc.edu> carroll@s.cs.uiuc.edu writes: > >I always thought that the 'no ; before END' part of PASCAL was one of the worst >'features' of the language. I can't count how many times I had to recompile >because I had added a statement before an END and forgotten to put a ; on >the *previous* statement. This is one of my pet peeves. That so many people do not know the easy answer to this problem signifies a serious problem in our educational system. Now watch my lips: ==> IT IS NOT AN ERROR TO PUT A SEMICOLON BEFORE AN END <== ==> IN THE STATEMENT SECTION OF A PASCAL PROGRAM. <== The BNF and railroad-tracks in Jensen&Wirth clearly indicate that the empty statement is part of the language. Any compiler that reports the error is broken. If the ISO standard has changed this, then the responsible parties should be forced to remove the offending semicolons from my programs with their teeth. Notice that the above statement says nothing about semicolons in record declarations nor procedure formal parameter declarations, nor about semicolons before ELSE keywords. There are, of course, those who take pride in using semicolon only for separators. Fine. They can have it. The CONCEPT of a separator is very simple. Execution is another matter. I personally make many errors when adding or deleting items in a parameter list; it's not that I don't understand the syntax, I just find it hard to see all the commas and non-commas in the list. If I modified parameter lists as often as I add and delete statements, I would find this situation annoying. Now go back to discussing important matters, like assembly language. Jon Mauney Computer Science Dept, NCSU mauney@cscadm.ncsu.edu