Skip Menu |

This queue is for tickets about the Regexp-Common CPAN distribution.

Report information
The Basics
Id: 51132
Status: open
Priority: 0/
Queue: Regexp-Common

People
Owner: Nobody in particular
Requestors: ruz [...] bestpractical.com
Cc:
AdminCc:

Bug Information
Severity: Wishlist
Broken in: 2010010201
Fixed in: (no value)



Subject: Fwd: Regexp::Common, small inheritability improvement
Date: Fri, 6 Nov 2009 01:00:31 +0700
To: bug-Regexp-Common <bug-Regexp-Common [...] rt.cpan.org>
From: Ruslan Zakirov <ruz [...] bestpractical.com>
Hello, Decided to move patch into RT. Released Regexp::Common::WithActions, but without the patch it sucks. Show quoted text
---------- Forwarded message ---------- From: Ruslan Zakirov <ruz@bestpractical.com> Date: 2009/11/3 Subject: Regexp::Common, small inheritability improvement To: Abigail <cpan@abigail.be> Hello Abigail, I don't know if you havn't recieved my emails or just ignored them. It doesn't matter. I'm ready to release R::C::WithActions to the CPAN, but one thing in the Regexp::Common makes this module very unflexible. In import function Regexp::Common unconditionally ties %RE hash. This brings very annoying requirement into usage of R::C::WithActions. Could you please apply attached patch and release a new version? -- Best regards, Ruslan. -- Best regards, Ruslan.

Message body is not shown because sender requested not to inline it.

Hello, Is there even tiny chance that the patch will be added into the distribution? On Thu Nov 05 13:01:02 2009, ruz@bestpractical.com wrote: Show quoted text
> Hello, > > Decided to move patch into RT. Released Regexp::Common::WithActions, > but without the patch it sucks. > > > ---------- Forwarded message ---------- > From: Ruslan Zakirov <ruz@bestpractical.com> > Date: 2009/11/3 > Subject: Regexp::Common, small inheritability improvement > To: Abigail <cpan@abigail.be> > > > Hello Abigail, > > I don't know if you havn't recieved my emails or just ignored them. It > doesn't matter. > > I'm ready to release R::C::WithActions to the CPAN, but one thing in > the Regexp::Common makes this module very unflexible. In import > function Regexp::Common unconditionally ties %RE hash. This brings > very annoying requirement into usage of R::C::WithActions. > > Could you please apply attached patch and release a new version? > > -- > Best regards, Ruslan. > > >
-- Best regards, Ruslan.
CC: undisclosed-recipients: ;
Subject: Re: [rt.cpan.org #51132] Fwd: Regexp::Common, small inheritability improvement
Date: Sat, 21 Nov 2009 14:23:10 +0100
To: Ruslan Zakirov via RT <bug-Regexp-Common [...] rt.cpan.org>
From: Abigail <abigail [...] abigail.be>
On Fri, Nov 20, 2009 at 09:01:25PM -0500, Ruslan Zakirov via RT wrote: Show quoted text
> Queue: Regexp-Common > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=51132 > > > Hello, > > Is there even tiny chance that the patch will be added into the distribution?
I won't say no, but there will not be a new release of Regexp::Common very soon. Abigail
Show quoted text
> I won't say no, but there will not be a new release of Regexp::Common > very soon.
Hello Abigail, I'm very glad you found time to release a new version of the distribution. Thank you for all hard work you do. In the attachment you can find test file for this patch. I hope that this test will help you make decision. Show quoted text
> Abigail
-- Best regards, Ruslan.
Subject: test_inheritance.t
# LOAD BEGIN {print "1..4\n";} package RC::SubClass; use Regexp::Common; sub import { my $self = shift; my $parent = ref tied %Regexp::Common::RE; $parent ||= 'Regexp::Common'; push @ISA, $parent unless $self->isa($parent); tie %Regexp::Common::RE, __PACKAGE__ if !defined tied %Regexp::Common::RE || !tied( %Regexp::Common::RE )->isa(__PACKAGE__); { no strict 'refs'; *{caller() . "::RE"} = \%Regexp::Common::RE; } } sub method { return "foo" } package main; # in some code we load subclass # in some code later we load original # make sure subclass stays RC::SubClass->import('delimited'); Regexp::Common->import('delimited'); print "ok 1\n"; print "not " unless ref(tied(%RE)) eq "RC::SubClass"; print "ok 2\n"; print "not " unless tied(%RE)->method eq "foo"; print "ok 3\n"; print "not " unless $RE{'quoted'}->method() eq "foo"; print "ok 4\n";
I converted this to pull request #6 on github. On Thu Nov 05 13:01:02 2009, ruz@bestpractical.com wrote: Show quoted text
> Hello, > > Decided to move patch into RT. Released Regexp::Common::WithActions, > but without the patch it sucks. > > > ---------- Forwarded message ---------- > From: Ruslan Zakirov <ruz@bestpractical.com> > Date: 2009/11/3 > Subject: Regexp::Common, small inheritability improvement > To: Abigail <cpan@abigail.be> > > > Hello Abigail, > > I don't know if you havn't recieved my emails or just ignored them. It > doesn't matter. > > I'm ready to release R::C::WithActions to the CPAN, but one thing in > the Regexp::Common makes this module very unflexible. In import > function Regexp::Common unconditionally ties %RE hash. This brings > very annoying requirement into usage of R::C::WithActions. > > Could you please apply attached patch and release a new version? > > -- > Best regards, Ruslan. > > >