Re: Subset w/ Inline::Perl5 RE as constraint

2020-11-08 Thread Joseph Brenner
I think this kind of thing does what you're after: use Inline::Perl5; my $p5 = Inline::Perl5.new; my $p5pat = '\w+'; $p5.run( 'sub chk { $_[0] =~ m/' ~ $p5pat ~ '/ }' ); subset p5_words of Str where { $p5.call( "chk", $^a ) }; my p5_words $a = "alpha"; say $a; # alpha, perl5 word chars, so acce

Re: Subset w/ Inline::Perl5 RE as constraint

2020-11-08 Thread Bruce Gray
> On Fri, Nov 6, 2020 at 8:23 AM Paul Procacci wrote: > > > > So two example patterns are: > > > > [\\u0009\\u000A\\u000D\\u0020-\\u007E\\u0085\\u00A0-\\uD7FF\\uE000-\\uFFFD\\u1-\\u10]* > > [\\p{L}\\p{Z}\\p{N}_.:\\/=+\\-@]* > > > > To note, the RE's themselves cannot be changed as they are

Re: Subset w/ Inline::Perl5 RE as constraint

2020-11-08 Thread Paul Procacci
Thank you Joseph, Your response along with Bruce's response (which I'll respond to separately) I presume works. My hopes of fitting this into a one liner are crushed! lol Nah, just playing. Thank you for taking the time to respond. This certainly helps with my project. ~Paul On Sun, Nov 8, 2

Re: Subset w/ Inline::Perl5 RE as constraint

2020-11-08 Thread Paul Procacci
Thank you Bruce, This does indeed help. Like I mentioned to Joseph I have yet to test it but because it's coming out of the SF Study group I imagine it works. ;) I'll certainly make noise if it doesn't. Appreciate the time given to a follow-up. ~Paul On Sun, Nov 8, 2020 at 7:42 PM Bruce Gray