summaryrefslogtreecommitdiff
path: root/Porting/bump-perl-version
diff options
context:
space:
mode:
authorFlorian Ragwitz <rafl@debian.org>2010-07-22 17:37:20 +0200
committerSteffen Mueller <smueller@cpan.org>2010-07-23 12:24:35 +0200
commit544af516d72dfd84bc12bd04e76b84740ab3f78c (patch)
tree5ccd305a0d1a9a14c0bf3ea7e43ec63854391cdd /Porting/bump-perl-version
parent6a3d1e7ec946e95930f5572e38977ee1c2e589a0 (diff)
downloadperl-544af516d72dfd84bc12bd04e76b84740ab3f78c.tar.gz
For blead, bump-perl-version should consider SUBVERSION as API_SUBVERSION
This makes the API version of a blead release equivalent to its full version number. For example, for 5.13.3, the API version was 5.13.0 before, and is 5.13.0 now. This does not change anything for stable releases. The API version of 5.14.1 will still be 5.14.0. Blead releases don't guarantee API stability. While they don't introduce API breakage on every release, they do so often enough to want to err on the safe side instead of making false claims in PERL_API_*.
Diffstat (limited to 'Porting/bump-perl-version')
-rwxr-xr-xPorting/bump-perl-version14
1 files changed, 7 insertions, 7 deletions
diff --git a/Porting/bump-perl-version b/Porting/bump-perl-version
index 04999e75b1..d7aabbab06 100755
--- a/Porting/bump-perl-version
+++ b/Porting/bump-perl-version
@@ -118,14 +118,14 @@ my @maps = (
],
[
qr{^(api_subversion(?:=|\s+)'?) (\d+) ('?) (?!\.)}x,
- sub { $2, "${1}0$3" },
- 0,
+ sub { $2, ($newy % 2) ? "$1$newz$3" : "${1}0$3" },
+ ($oldy % 2) ? $oldz : 0,
qr/config/,
],
[
qr{^(api_versionstring(?:=|\s+)'?) ([\d\.]+) ('?) (?!\.)}x,
- sub { $2, "$1$newx.$newy.0$3" },
- "$oldx.$oldy.0",
+ sub { $2, ($newy % 2) ? "$1$newx.$newy.$newz$3": "$1$newx.$newy.0$3" },
+ ($oldy % 2) ? "$oldx.$oldy.$oldz" : "$oldx.$oldy.0",
qr/config/,
],
[
@@ -142,12 +142,12 @@ my @maps = (
[
qr{\b (PERL_SUBVERSION(?:=|\s+)'?) (\d+) ('?) (?!\.)}x,
sub { $2, "$1$newz$3"},
- $oldz,
+ ($oldy % 2) ? $oldz : 0,
],
[
qr{\b (PERL_API_SUBVERSION(?:=|\s+)'?) (\d+) ('?) (?!\.)}x,
- sub { $2, "${1}0$3"},
- 0,
+ sub { $2, ($newy % 2) ? "$1$newz$3" : "${1}0$3" },
+ $oldz,
],
# these two formats are in README.vms
[