On 3/7/07, demerphq <demerphq@gmail.com> wrote: > On 3/7/07, Rafael Garcia-Suarez <rgarciasuarez@gmail.com> wrote: > > On 07/03/07, demerphq <demerphq@gmail.com> wrote: > > > Attached patch will get the show on the road for building, but won't > > > fix the minitest failures (ill followup with a patch for that). > > > > Thanks, applied as #30496. > > > > Note that this glob failure is now back : > > $ bleadperl -wle 'print*-{HASH}{foo}' > > Can't locate object method "FETCH" via package > > "re::Tie::Hash::NamedCapture" at -e line 1. > > > > That's because the tied hashes %+ and %- are always created, even when > > the variable requested is @+ or $-. Unfortunately if I try to create > > the hashes only when requested, regexp tests start to fail :-( > > > > Maybe it's better to move some of the tied class code into perl, so > > loading an external module is no longer necessary. > > Done with the attached patch. It required changing and renaming > re::Tie::Hash::NamedCapture to Tie::Hash::NamedCapture as it needs to > be in /lib but the makefile code for distclean is set up to delete > lib/re so the easiest workaround was to just move it out of the > ext/re/ branch and rename it so it wasnt under lib/re at all. > > The patch only includes the add, and not the delete. (Not sure why svn > does that) > > Also the process of going from ext/re/re.xs => ext/re/re.c => > universal.c meant that the new code that ended up in universal.c is > kinda crude. It could do with some cleanup of the automatically added > code done by the XS=>C converter and maybe a review by someone who > knows XS better than I do. Anyway, for now tho its fine IMO. > > The patch includes changes that would come from a regen. But it might > be a good idea to redo it. And here is a refinement, which does the tieing of %- and %+ in the same way that %! is done, and also fixes %! when glob trickery occurs with it. This should be applied after the previous patch i sent in. cheers, yves -- perl -Mre=debug -e "/just|another|perl|hacker/"Thread Previous | Thread Next