Historical language survey

Fredrik Olsson peylow at gmail.com
Fri Jul 7 12:37:37 PDT 2006


Sean Kelly skrev:
> Fredrik Olsson wrote:
> 
>> Sean Kelly skrev:
>>
>>> kris wrote:
>>
>> <snip>
>>
>>>> Eh? We're talking about the language according the Wirth here (as 
>>>> Walter notes vis-a-vis Wirth's book). Somebody here ought to note 
>>>> that Pascal was designed *solely* as an educational tool, for 
>>>> /teaching structured programming/ ... the syntax and design was 
>>>> never intended as a solution for general-purpose systems 
>>>> programming. It's silly to compare it to C
>>>
>>>
>>>
>>> Yup.  And for that I think it was well-designed.  The syntax is clear 
>>> and free of arcane symbology, and irritating enough to use for real 
>>> work that students are well inclined to move on when they learn a 
>>> more professional language ;-)  The pointer syntax in Pascal drives 
>>> me absolutely insane.
>>>
>> Am I the only one in the world that thinks the pointer syntax in 
>> Pascal beats the C and D syntax every time?
>>
>> I mean how hard can it be:
>> ^foo  == a pointer type, pointing to a foo. foo* works, but * also mul.
>> foo^  == Whatever the pointer foo points to. *foo works, same argument.
>> @bar  == The pointer of bar. &bar works to, but why reuse & again?
> 
> 
> I think the '@' in place of '&' is quote meaningful, but for the rest... 
> it just didn't seem intuitive to me.  It's been quite a while, but I 
> remember really feeling like I was fighting the language once I got to 
> pointers.
> 
>> Now original Pascal, or even ANSI Pascal is hideous, that I can agree 
>> with. But I also think that turning the blind eye on what has been 
>> done with Turbo Pascal and Delphi the last two decades is idiotic. 
>> Especially since they have been more or less the de facto standard 
>> Pascal. And thus what Pascal should be judged by.
> 
> 
> I was referring to original Pascal.  I've used Delphi quite a bit as 
> well, and while I'm still not crazy about the updated syntax, it's 
> really quite a good system to work with in general.
> 
> 
> Sean

My _only_ gripe with Pascal is case insanity! Unfortunately the more I 
write in anything else, the more I fail see an excuse :).
foo := Foo.Create();
Should be legal, but as is (and far too late to fix) we are stuck with 
ugly and stupid prefixes like:
foo := TFoo.Create();
Every class in VCL being named T... is stupidity.

But that aside, Delphi and Pascal makes it easy to be productive, write 
less, and more bug free code to solve the same problem as in other 
languages.
Yet again I must point out that D really should have sets and ranges! ;)

// Fredrik



More information about the Digitalmars-d mailing list