Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

infix:= converts a PGE::Match to a Str, not a Match #175

Closed
p6rt opened this issue Jul 19, 2008 · 5 comments
Closed

infix:= converts a PGE::Match to a Str, not a Match #175

p6rt opened this issue Jul 19, 2008 · 5 comments
Labels

Comments

@p6rt
Copy link

p6rt commented Jul 19, 2008

Migrated from rt.perl.org#57094 (status was 'resolved')

Searchable as RT57094$

@p6rt
Copy link
Author

p6rt commented Jul 19, 2008

From @cjfields

infix​:= converts PGE​::Match to a Str, not a Match. This requires the
latest patch from RT#​56970 (simple match() implementation). .match
should return a Match object.

jonathan++ for working this one out. See​:

http://www.nntp.perl.org/group/perl.perl6.compiler/2008/07/msg2089.html

Following is a small test script demonstrating the problem.

my $x = "foo";

my $y = $x.match(/o+/);
say $y;
say $y.WHAT;

say ($x.match(/o+/)).WHAT; # Match

chris

@p6rt
Copy link
Author

p6rt commented Nov 12, 2008

From @moritz

On Fri Jul 18 19​:08​:44 2008, cjfields wrote​:

infix​:= converts PGE​::Match to a Str, not a Match. This requires the
latest patch from RT#​56970 (simple match() implementation). .match
should return a Match object.

jonathan++ for working this one out. See​:

http://www.nntp.perl.org/group/perl.perl6.compiler/2008/07/msg2089.html

Following is a small test script demonstrating the problem.

my $x = "foo";

my $y = $x.match(/o+/);
say $y;
say $y.WHAT;

Status after the container refactor​: it returns an empty hash now (r32577).

@p6rt
Copy link
Author

p6rt commented Nov 12, 2008

The RT System itself - Status changed from 'new' to 'open'

@p6rt
Copy link
Author

p6rt commented Dec 5, 2008

From @jnthn

Hi,

After checking with the latest Rakudo, I think this issue is now
resolved. We get​:

my $x = "food";
my $y = $x.match(/$<x>=[f](o+)/);
say $y.WHAT; # Match
say $y; # foo
say $y<x>; # f
say $y[0]; # oo

However, this still failed​:

say $y ~~ Match; # gave 0

So I fixed that in 33504, and I think this ticket is done now. I also
unfudged the tests for the type checking against Match and added a tests
that assigns a match object to a scalar and uses it as above.

Thanks,

Jonathan

@p6rt
Copy link
Author

p6rt commented Dec 5, 2008

@jnthn - Status changed from 'open' to 'resolved'

@p6rt p6rt closed this as completed Dec 5, 2008
@p6rt p6rt added the Bug label Jan 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant