[TUHS] Why Pascal is Not My Favorite Programming Language - Unearthed!

Larry McVoy lm at mcvoy.com
Fri Sep 1 11:26:55 AEST 2017


On Thu, Aug 31, 2017 at 06:22:41PM -0700, Bakul Shah wrote:
> 
> > On Aug 31, 2017, at 2:46 PM, Larry McVoy <lm at mcvoy.com> wrote:
> > 
> > On Thu, Aug 31, 2017 at 04:37:17PM -0400, William Cheswick wrote:
> >> I look to the likes of go and rust to get us back on track.  C is a pretty good assembly language.
> > 
> > So what chaps my grumpy old hide is why the heck do a whole new language
> > when you have one that is pretty good?  Suppose we took C and added a
> > dialect via options:
> > 
> > 	--no-ptrs	// use arrays and indices, you get bounds checking
> > 	--strings	// system managed memory for strings, like tcl
> > 	--perlisms	// if (buf =~ /re/) and unless (it_worked())
> 
> Such a language would stop being C.

Indeed.  But it builds on C.

> In Go you can use slices instead of arrays (but slices are only one dimensional).
> Ptrs are relatively safe as memory is garbage collected so e.g. a function can
> return &local_variable. No perlism.
> 
> Go provides other features which are quite useful: concurrency, channels,
> interfaces, packages.
> 
> People who like C tend to like Go. But Go is not low-level enough. No one
> is writing a kernel in it! Or doing bare metal programming. AFAIK.

Exactly.

> > etc.  Why create an entirely new language, new syntax, new linkage, etc,
> > instead of fixing C's shortcomings?
> 
> C has too many problems. If you try fixing them, none of the "dusty decks"
> would run on such a compiler + the new language would be severely
> hampered in its evolution due to its C legacy.

So I'd need to understand more to believe that claim.  And for the record,
what I'm going for is a new C that is still C enough to be useful but
fixes the problems enough to be a new language.  Someone asked about
C++ and D, nope.  Too far from C.  I just want a C that fixes enough
of the problems that it is more acceptable to modern programmers but
is still C.  Not sure if I'm explaining that well enough.

> Algol family, class based, prototype based, functional, array, logic,
> visual, ... programming language are just what we have tried so far. 
> I don't think we are anywhere near the end of programming language
> evolution.

Yep.

-- 
---
Larry McVoy            	     lm at mcvoy.com             http://www.mcvoy.com/lm 



More information about the TUHS mailing list