Leading 0's syntax error in datetime.date module (Python 3.6)
Jon Ribbens
jon+usenet at unequivocal.eu
Thu May 10 15:04:58 EDT 2018
On 2018-05-10, Skip Montanaro <skip.montanaro at gmail.com> wrote:
>> I wonder why someone would take a feature generally agreed to be a
>> poorly designed feature of C, and incorporate it into a new language.
>
> I think you might be looking at a decision made in the late 1980s through a
> pair of glasses made in 2018.
>
> As a C programmer back then I never had a problem with C's octal number
> notation. People coming from C, C++ or Java to Python at that time would
> certainly have understood that syntax. It's only in the past 15 years or so
> that we've seen tons of people coming to Python as a first language for
> whom leading zero notation would be unfamiliar.
This whole thread is reminding me PHP 2, which would magically treat
the second parameter of ChMod() as octal, because clearly if weak
typing is good then *no* typing must be best of all!
ChMod($filename, 644); // second parameter is actually 420 base 10
More information about the Python-list
mailing list