develooper Front page | perl.perl5.porters | Postings from March 2018

[perl #132935] [PATCH] ExtUtils::ParseXS: use literals for VERSIONin 'use Module VERSION'

Thread Previous
From:
James E Keenan via RT
Date:
March 5, 2018 02:24
Subject:
[perl #132935] [PATCH] ExtUtils::ParseXS: use literals for VERSIONin 'use Module VERSION'
Message ID:
rt-4.0.24-22761-1520216652-140.132935-15-0@perl.org
On Sun, 04 Mar 2018 07:10:18 GMT, skaji@outlook.com wrote:
> This is a bug report for perl from skaji@outlook.com,
> generated with the help of perlbug 1.40 running under perl 5.26.1.
> 
> 
> -----------------------------------------------------------------
> [Please describe your issue here]
> 
> Currently in ExtUtils::ParseXS, the version check does not work
> because we use variables for VERSION:
> 
> ```
> our $VERSION;
> BEGIN {
>   $VERSION = '3.38';
> }
> use ExtUtils::ParseXS::Constants $VERSION;
> ```
> 
> We must use literals for VERSION.
> A patch for this is attached to this e-mail.
> 

Please see the explanation provided by Steffen Mueller in commit 71a65ad3b4b0678fcf5bd6ac3b7ad394accc8079 back in 2011:

#####
ExtUtils::ParseXS: Explicitly require current version of submodules

Since there have been certain problems with parts of ExtUtils::ParseXS being shadowed by older installations of the module, this commit adds an explicit $VERSION to all submodules and requires them to have the same version as the main module. This doesn't actually fix any problem, but makes them more apparent as early as possible instead of failing with obscure compile errors when bad C is generated from the original XS.
#####

Thank you very much.

-- 
James E Keenan (jkeenan@cpan.org)

---
via perlbug:  queue: perl5 status: new
https://rt.perl.org/Ticket/Display.html?id=132935

Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About