The Polite Fiction of Numbering

| 2 Comments

(or burying the lede on a Saturday morning)

David Golden commented on internal perceptions and evolution of Perl:

If Perl 5 is a language (and not just an interpreter), how fast should that language evolve and what "versioning" signifies significant change.

One reason people debate so hotly the naming of "Perl 6" is the magic tied to a version number. I've written many times that "Perl can never break backwards compatibility in a radical way because it's never broken backwards compatibility before." That's a common belief. It's also a common belief that it's only okay to correct some of the flaws of Perl (especially missing defaults) by breaking backwards compatibility and signifying that change by incrementing a magical version number.

Of course a number is just a number and a version is just a version and a belief—no matter how wide spread—is just a belief. It may even be a myth. Certainly it's falsifiable.

One little change to Perl would instantly make all of these things possible without requiring Larry to invoke rule #2 on the naming of Perl 6: if Perl 5.16 (or 5.18) required the explicit declaration of the version of Perl any particular file or lexical scope used and defaulted to "whatever the most current version of the perl binary used to run the program provides".

That simple act of declaration (and not-quite-heroic work for backwards compatibility pushed the direction it belongs instead of externalized from the enterprisey to volunteers) could solve so many problems. All it takes is a slight shift in culture and character and, yes, belief.

2 Comments

Perhaps it's just me, but I thought that declaring the version of perl 5 to use was the 'best' method of dealing with incremental changes. In line with having multiple versions installed on one machine and pointing to them with the #!, it makes absolute sense to declare which version of convenience that your program should use. Being able to write Perl 5.8 code on Perl version 5.22 is 'useful' in ways you can probably imagine. If Perl 6 cannot or should not be backward compatible there is no problem. Installing version 5 and 6 on one machine is of little consequence in practical terms.

If my program is written for version 5.12 and only 5.10 is available on the machine the 'use Version' should report the failure and avoid confusing errors elsewhere. This only makes sense. It seems so natural that anything else would IMO be confusing. The world in general has many windows users. None of them are wont to believe that they can take an application for Windows 7 and be able to install and run it on Windows 98. When they do try it Windows tells them it won't work. This is an expected behavior. I would expect Perl to do the say with version variances which change over time. It just makes sense.

Currently use 5.14.1; means "Use any version equal to or newer than 5.14.1". The proposal would change that to mean "Use the semantics of only version 5.14.1."

Modern Perl: The Book

cover image for Modern Perl: the book

The best Perl Programmers read Modern Perl: The Book.

affiliated with ModernPerl.net

Categories

Pages

About this Entry

This page contains a single entry by chromatic published on July 9, 2011 11:18 AM.

Less Magic, Less C, A Faster Parrot was the previous entry in this blog.

Free Tools for Free Books is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.


Sponsored by Blender Recipe Reviews and the Trendshare how to invest guide

Powered by the Perl programming language

what is programming?