Assignment Versus Equality

Lawrence D’Oliveiro lawrencedo99 at gmail.com
Mon Jun 27 18:45:19 EDT 2016


On Tuesday, June 28, 2016 at 3:27:40 AM UTC+12, MRAB wrote:
> On 2016-06-27 14:59, Grant Edwards wrote:
>> Why would a language designer think it a good idea?
>>
> It let you have identifiers like "grand total"; there was no need for 
> camel case or underscores to separate the parts of the name.

Another nifty thing (well, I thought so at the time) was that FORTRAN had no reserved words.

Though I wondered, in statements like

    FORMAT(...complex expression with lots of nested parentheses...) = ...

how much work the parser would have to do before deciding that it was an array assignment, not a FORMAT statement?

Then some FORTRAN dialects allowed constant definitions using syntax like

    PARAMETER N = 3

which broke the no-reserved-words convention. Luckily, this was standardized as the much less headache-inducing (for the compiler writer)

    PARAMETER(N = 3)

PL/I (which was almost named “FORTRAN VI” at one stage) added significant whitespace, but managed to keep the no-reserved-words convention--almost. There was just one peculiar set of exceptions...



More information about the Python-list mailing list