Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!usc!ucsd!ucbvax!WORLD.STD.COM!bzs From: bzs@WORLD.STD.COM (Barry Shein) Newsgroups: comp.society.futures Subject: C's sins of commission (was: (pssst...fortran?)) Message-ID: <9009141908.AA24760@world.std.com> Date: 14 Sep 90 19:08:57 GMT References: <1990Sep14.160429.2732@abcfd20.larc.nasa.gov> Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 65 >>This leads us to pointers. Just about everything about C pointers is >>bad. From the fact that pointers are hopelessly confused with arrays >>(which are completely separate conceptually) to the syntax of pointer >>use, C's pointers are a mess. > >Not a mess, just cryptic, as is most of C. C IS NOT a high level >language, it was originally designed as a mid-level language, somewhere >between Pascal and Assembler...it is NOT designed to be used by novice! I think we're working from axioms here that may not be self-evident. For example, HLLs are easier for novices than MLLs. I don't know if that's true or not. Novices make a lot of semantic errors. HLL's provide such a high level of abstraction and so many complicated rules that it's nearly impossible to explain why something is wrong, or in particular, figure it out for yourself. The PL/I manual set (an HLL if there ever was one) was something like 19 linear shelf-feet. The rules for arithmetic alone demanded an understanding of all sorts of issues. MLL's like C provide a very simple semantics (can be explained in a few dozen pages) but a reasonably high-level syntax. That is, "algebraic", analogous to what is learned in grade-school math rather than having to do the translation needed for assembler etc. Pascal is considered an HLL. I've taught several languages over the years to college students. Pascal had to be one of the worst, most kids couldn't get past where the semi-colons go. That sort of subtlety and worshipping of abstraction is typical of HLL's. Also, most students have problems with pointers because their teachers didn't understand them. No joke. Somewhere they became these bogey-men and teachers in intro courses would stand up there and give all these signals to the class that what s/he is about to teach is impossible to understand so here we go... I just told them funny stories about the confusions between the thing and the thing contained ("The White House said today...") and went on with it and never had any problems. A location is not really a hard problem, houses have addresses etc, pigeon-holes with box numbers and so forth. The hard problem was lousy teachers with worse attitudes. Self taught programmers almost never had any problem with pointers or thought they were particularly interesting/challenging/whatever. I think the future of programming, however, lies in moving the solution of the problem closer to the problem. Programming languages are for programmers, people trained in a specific skill. People who do not have that training should have applications packages and generators. Remember, it wasn't that long ago that when we wanted a simple graph we used to write a program. Today it would be rare to do that. The point being, that trying to make programmers out of everyone (typically by designing languages so easy to use even "your secretary" could program...that was absolutely beyond a doubt the typical sexist claim, I was there) was a strange, 1970's dream that by and large has become unnecessary. Programming is a skill, like driving a semi, most people shouldn't need that skill.