rentsch@unc.cs.unc.edu (Tim Rentsch) (07/04/87)
In some previous article lindsay@cheviot (Lindsay F. Marshall) writes: > > I think mesa is a dreadful language. Interesting opinion. Would you mind defending your opinion with some facts (or even just some reasons)? > Mesa is the most verbose Algol-like language I have ever used (much > worse than Ada) and it is full of the most ridiculous syntax I have ever > come across. As for it's much vaunted type safety, if you look at any > large programs written in it they all make massive use of the "loophole" > facility to avoid the type-checking....... Oh, come now. Mesa syntax worse than Ada? How many syntax rules does Mesa have? How many does Ada have? (Offhand I have no idea, although I have seen collected syntax rules for both.) "Ridiculous" is a fairly subjective word -- would you mind at least telling us what you mean by "ridiculous", or give some examples (contrast the examples with others from Ada or Modula which are not "ridiculous", if you don't mind). As for type safety, I have looked at (and worked on) large programs written in Mesa, and they did not make "massive" use of loophole. To be sure, there were 'loophole's used, but at those places where the type of something was being changed, so as to facilitate stronger type checking elsewhere. Not massive, by any means. Would you have us go the C route, where loophole is unnecessary because everything is an int? Please excuse the mild heat, it just bothers me when someone posts an article which says "my opinion is x" without giving some substance or explanation for why his opinion is what it is. cheers, Tim
henry@utzoo.UUCP (Henry Spencer) (07/07/87)
> As for type safety... Would > you have us go the C route, where loophole is unnecessary because > everything is an int? How many years has it been since you used C? Modern C is fairly strongly typed, and getting more so all the time. (Note that if you are using a PCC-based compiler, you are working with an implementation that is nearly ten years old.) (If it's the one in 4.3BSD, it's also seriously buggy.) -- Mars must wait -- we have un- Henry Spencer @ U of Toronto Zoology finished business on the Moon. {allegra,ihnp4,decvax,pyramid}!utzoo!henry
rentsch@unc.cs.unc.edu (Tim Rentsch) (07/08/87)
In article <8268@utzoo.UUCP> henry@utzoo.UUCP (Henry Spencer) writes: > > As for type safety... Would > > you have us go the C route, where loophole is unnecessary because > > everything is an int? > > How many years has it been since you used C? Modern C is fairly strongly > typed, and getting more so all the time. (Note that if you are using a > PCC-based compiler, you are working with an implementation that is nearly > ten years old.) (If it's the one in 4.3BSD, it's also seriously buggy.) I use C all the time, although it is (mostly) 4.3BSD. On the other hand, I thought the C language definition (as opposed to any particular implementation) is "pointers are ints" and so forth. Am I wrong? (By language definition I mean K&R, of course, not any proposed standard.) Or are you just telling me that C compilers are getting better? That's a different horse altogether... cheers, Tim
ekb@ho7cad.UUCP (07/09/87)
In article <764@unc.cs.unc.edu>, rentsch@unc.cs.unc.edu (Tim Rentsch) writes: > On the other hand, I thought the C language definition (as opposed to > any particular implementation) is "pointers are ints" and so forth. > Am I wrong? (By language definition I mean K&R, of course, not any > proposed standard.) Or are you just telling me that C compilers are > getting better? That's a different horse altogether... I do not agree that K&R say that "pointers are ints". At the end of section 7.14 of Appendix A, they say that "currently", compilers do allow assignment between integers [not necessarily "int"s] and pointers, but that the usage is non-portable. I would interpret this as just saying that the compilers of that time were rather flexible about this, but that it was not really condoned. = Eric
elg@killer.UUCP (Eric Green) (07/10/87)
in article <764@unc.cs.unc.edu>, rentsch@unc.cs.unc.edu (Tim Rentsch) says: >> > As for type safety... Would >> > you have us go the C route, where loophole is unnecessary because >> > everything is an int? >> >> How many years has it been since you used C? Modern C is fairly strongly >> typed, and getting more so all the time. > On the other hand, I thought the C language definition (as opposed to > any particular implementation) is "pointers are ints" and so forth. > Am I wrong? (By language definition I mean K&R, of course, not any > proposed standard.) Or are you just telling me that C compilers are > getting better? That's a different horse altogether... Page 102, _The C Programming Language_ by Brian W. Kernighan and Dennis M. Ritchie, 1978 paperback addition, section 5.6: " 5.6 Pointers are not Integers You may notice in older C programs a rather cavalier attitude toward copying pointers. It has generally been true that on most machines a pointer may be assigned to an integer and back again without changing it; no scaling or conversion takes place, and no bits are lost. Regrettably, this has led to the taking of liberties with routins that return pointers which are then merely passed to other routines --- the requisite pointer declarations are often left out. For example, consider...." [goes on with a lengthy example of a bogosity]. In other words, an int has never been a pointer, never was, never will be. Case closed! -- Eric Green {cbosgd,ihnp4}!killer!elg, elg@usl.CSNET
lindsay@cheviot.newcastle.ac.uk (Lindsay F. Marshall) (07/10/87)
In article <749@unc.cs.unc.edu> rentsch@unc.UUCP (Tim Rentsch) writes: >Interesting opinion. Would you mind defending your opinion with >some facts (or even just some reasons)? I just think the language is too verbose. I hate Pascal with an intensity you cannot even begin to conceive, and Mesa is really just Pascal with a few bells and whistles. One of the other major problems is the environment in which it lifes. Perhaps if Mesa werent embedded inside all the XDE stuff (where my Mesa experience coems from) it might seem better. I doubt it. (Though look what C is like under XDE/Viewpoint - hello.c takes 6 pages of code!!!) I also think that the style rules promulgated by the Mesa community make for unreadable, incomprehensible programs. >Oh, come now. Mesa syntax worse than Ada? How many syntax rules >does Mesa have? How many does Ada have? (Offhand I have no idea, >although I have seen collected syntax rules for both.) I didnt say anything about the amount of syntax! Ada programs look much cleaner than Mesa ones, at least in my opinion. > "Ridiculous" >is a fairly subjective word -- would you mind at least telling us >what you mean by "ridiculous", or give some examples Ridiculous means "deserving or inviting ridicule". Mesa programs always induce that response in me. Great masses of dense code that dont do very much. Again I am talking about programming in Mesa in the XDE environment, in a sensible environment perhaps it wouldnt look so bad. >As for type safety, I have looked at (and worked on) large programs >written in Mesa, and they did not make "massive" use of loophole. >To be sure, there were 'loophole's used, but at those places where >the type of something was being changed, so as to facilitate >stronger type checking elsewhere. Not massive, by any means. The programs I have looked at used loophole a lot, for what reason's were never clear to me - I find the language incomprehensible. I find C's method of coercions much easier to understand use. >Would you have us go the C route, where loophole is unnecessary because >everything is an int? If you believe that about C then you dont understand the language very well!! I have this fight (C v Mesa) with lots of people. I really detest Mesa and other Pascal clones (I dont like Ada or Modula 2 very much either). I DONT think that C is the best language in the world either!! But it lets me express what I want in clear easy to read and understand ways, without baroque syntax and without wearing out the keyboard typing all those enormous keywords.... (BTW I find the Berkeley style of C programming almost as unreadable as Mesa........) Lindsay -- Lindsay F. Marshall JANET: lindsay@uk.ac.newcastle.cheviot ARPA: lindsay%cheviot.newcastle@ucl-cs PHONE: +44-91-2329233 UUCP: <UK>!ukc!cheviot!lindsay "How can you be in two places at once when you're not anywhere at all?"
sperry@ur-valhalla.UUCP (Bob Sperry) (07/13/87)
I strongly disagree with the contention that Mesa is a dreadful language, especially if the comparison is to C. I feel that C is a hackers langage which is unsuitable for the development of large software systems. I would consider the proof of this contention to be UNIX. As to the contention that Mesa is Pascal with a few extra whistles and bells, I again disagree. Their are two principle differences between the two. First of all, Pascal does not have the langage constructs necessary for coordinating multiple light-weight processes (i.e. monitors, and condition variables). Secondly, Pascal is not oriented towards large systems, and incremental binding ( i.e. directory, imports, exports). I feel that a language is only a single component of the overall system, and it is this system which should be evaluated. In the case of C this system is often UNIX. In the case of Mesa, this system is XDE. For the personal workstation environment, I feel that XDE is a major improvement over UNIX. The major disadvantage of XDE is embedded in the first letter of the acronym. If Xerox offered XDE on the SUN, I believe it would supplant UNIX as the most popular operating system for personal workstation class machines.
dcw@doc.ic.ac.uk (Duncan C White) (07/14/87)
In article <8268@utzoo.UUCP> henry@utzoo.UUCP (Henry Spencer) writes: >> As for type safety... Would >> you have us go the C route, where loophole is unnecessary because >> everything is an int? > >How many years has it been since you used C? Modern C is fairly strongly >typed, and getting more so all the time. (Note that if you are using a >PCC-based compiler, you are working with an implementation that is nearly >ten years old.) (If it's the one in 4.3BSD, it's also seriously buggy.) >-- Good grief, Henry.... this is an extremely unhelpful attitude: "the PCC compiler [ie. the standard C compiler as distributed on BSD UNIX] isn't real C.. it's ten years out of date": what do you suggest all the BSD UNIX users DO about having a compiler that's ancient history ? Now I certainly agree that it would be very nice to have prototypes .. they are the single most useful change to the language ever.. Duncan. ----------------------------------------------------------------------------- JANET address : dcw@uk.ac.ic.doc| Snail Mail : Duncan White, --------------------------------| Dept of Computing, This space intentionally | Imperial College, left blank...... | 180 Queen's Gate, (paradoxical excerpt from | South Kensington, IBM manuals) | London SW7 ---------------------------------------------------------------------------- Tel: UK 01-589-5111 x 4982/4991 ----------------------------------------------------------------------------
eugene@pioneer.arpa (Eugene Miya N.) (07/14/87)
This is an amazing discussion. {Anybody for angel dancing on pin heads?} Look, they are all imperative languages: C [my personal day to day language], Pascal [sorry, I have my name on the early standards document], ALGOL [58,60,68], CLU [my favorite language which I can't use], Modula (1 and 2 [`cleaned' up Mesa]), Mesa, PL/1, Ada, Jovial, CORAL, even FORTRAN is looking more and more ALGOL like. Sure, there are slight differences in syntax rules: cascading cases, strong typing, etc., but they are all basically the same. LISP is different. Simula is different (throw Smalltalk here). Make comparison in this area (how about TECO and PostScript as programming languages...;-) From the Rock of Ages Home for Retired Hackers: --eugene miya NASA Ames Research Center eugene@ames-aurora.ARPA "You trust the `reply' command with all those different mailers out there?" "Send mail, avoid follow-ups. If enough, I'll summarize." {hplabs,hao,ihnp4,decwrl,allegra,tektronix,menlo70}!ames!aurora!eugene
dld@theory.cs.cmu.edu (David Detlefs) (07/14/87)
Eugene Miya makes a very valid point -- whenever I hear people arguing over the relative merits of, say, C and Pascal, I immediately lose interest in the discusssion, and some measure of intellectual respect for the participants. The same goes for people who complain that having to type out keywords is one of the major impediments to their getting their work done -- MAYBE they are such great programmers that the limit on their productivity is typing speed, but I doubt it. However, while I agree with the spirit of Eugene's post, I would like to disagree with some particulars (thus, probably becoming just the kind of person I'm complaining about, but this bboard is not meant for rational discussion anyway.) I would agree that C, Pascal, Mesa, the Algols, and the Modulas form a rough equivalence class. I think there is a very important difference between these and Fortran, however: Fortran does not have a pointer type. To create a linked list in Fortran takes some pretty fancy gyrations. (I'm not sure, but isn't Jovial similar in this regard?) Maybe the latest versions of Fortran have raised it into the above equivalence class; I don't know. Eugene mentioned that CLU was his favorite language that he didn't get to use; it's my favorite language also, and I don't get to use it. I think perhaps a reason we both like it is also a reason it doesn't belong in this equivalence class: it offers garbage-collected heap storage. In this respect it is more like a strongly typed Lisp than it is like any of the other languages. (I think maybe the DEC implementation of Modula II uses a garbage collector as well?) Anyway, system implementers have often commented that some very high percentage of the bugs in systems implemented in langauges from the first equivalence class are due to the complexities of storage management. I think that the elimination of these bugs by using garbage collection forms a valid basis for distinguishing these langauges. To move this discussion up a philosophical level -- I think a much more interesting discussion than "Is language X better than language Y?" is "What are the axes along which languages differ, and which points in the design space formed by these axes work well?" Missing CLU, Dave
karl@haddock.ISC.COM (Karl Heuer) (07/15/87)
In article <1063@theory.cs.cmu.edu> dld@theory.cs.cmu.edu (David Detlefs) writes: >I would agree that C, Pascal, Mesa, the Algols, and the Modulas form a rough >equivalence class. I think there is a very important difference between >these and Fortran, however: Fortran does not have a pointer type. It's all a matter of degree. C has a powerful pointer type; Pascal has something they call a pointer but you can't use it to store the address of a variable; Fortran uses array indices. A "pointer" in Fortran is a pair <i,a> where i is an integer and a is a (constant) array name. I'd put them all in the same equivalence class, along with Basic. Karl W. Z. Heuer (ima!haddock!karl or karl@haddock.isc.com), The Walking Lint
lindsay@cheviot.newcastle.ac.uk (Lindsay F. Marshall) (07/16/87)
In article <1064@ur-valhalla.UUCP> sperry@ur-valhalla.UUCP (Bob Sperry) writes: >As to the contention that Mesa is Pascal with a few extra whistles and >bells, I again disagree. I was repeating what people who'd worked on the language told me... >I feel that a language is only a single component of the overall >system, and it is this system which should be evaluated. In the case >of C this system is often UNIX. In the case of Mesa, this system is >XDE. For the personal workstation environment, I feel that XDE is a >major improvement over UNIX. The major disadvantage of XDE is embedded >in the first letter of the acronym. If Xerox offered XDE on the SUN, I >believe it would supplant UNIX as the most popular operating system >for personal workstation class machines. XDE is a pile of junk. I have a 6085 that runs Viewpoint and XDE. The only use I have for XDE is to run the Maryland bridge software so that I can get to a usable system - UNIX. The fundamental design behind the system is unsound - this strange "single user" model of the world they have just doesnt reflect the way I (or anyone else I have ever met) works. If XDE were offered on the SUN instead of UNIX, SUN would be out of business in a week. You can tell the system is a mess when you look at the programming interface provided to it. The thing has obviously grown without control and nobody has done the right thing - throw it away and start again. You cant stop a program that's running unless the program supports it itself (half the time trying this will crash the system), you cant even interrupt most of the programs and the processor is so slooooooooow that you can be stuck for 10-15 minutes before you can get out (if it doesnt crash of course and give you some really helpful diagnostic like 0956......) Give me Viewpoint any day!! Lindsay -- Lindsay F. Marshall JANET: lindsay@uk.ac.newcastle.cheviot ARPA: lindsay%cheviot.newcastle@ucl-cs PHONE: +44-91-2329233 UUCP: <UK>!ukc!cheviot!lindsay "How can you be in two places at once when you're not anywhere at all?"