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

say "a" ~~ m:nth(Mu)/a/ dies with maximum recursion depth exceeded #2091

Closed
p6rt opened this issue Aug 24, 2010 · 7 comments
Closed

say "a" ~~ m:nth(Mu)/a/ dies with maximum recursion depth exceeded #2091

p6rt opened this issue Aug 24, 2010 · 7 comments

Comments

@p6rt
Copy link

p6rt commented Aug 24, 2010

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

Searchable as RT77408$

@p6rt
Copy link
Author

p6rt commented Aug 24, 2010

From @bbkr

On Pisa build

$ perl6 -e 'say "a" ~~ m​:nth(Mu)/a/'
maximum recursion depth exceeded
  in 'EnumMap​::Capture' at line 4867​:CORE.setting
  in 'EnumMap​::Capture' at line 4871​:CORE.setting
  in 'prefix​:<|>' at line 677​:CORE.setting
  in 'Cool​::match' at line 2398​:CORE.setting
  in 'Cool​::match' at line 2398​:CORE.setting
  in 'Cool​::match' at line 2398​:CORE.setting
  in 'Cool​::match' at line 2398​:CORE.setting
...

@p6rt
Copy link
Author

p6rt commented Oct 1, 2011

From @coke

On Tue Aug 24 04​:17​:36 2010, pawel.pabian@​implix.com wrote​:

On Pisa build

$ perl6 -e 'say "a" ~~ m​:nth(Mu)/a/'
maximum recursion depth exceeded
in 'EnumMap​::Capture' at line 4867​:CORE.setting
in 'EnumMap​::Capture' at line 4871​:CORE.setting
in 'prefix​:<|>' at line 677​:CORE.setting
in 'Cool​::match' at line 2398​:CORE.setting
in 'Cool​::match' at line 2398​:CORE.setting
in 'Cool​::match' at line 2398​:CORE.setting
in 'Cool​::match' at line 2398​:CORE.setting
...

This no longer dies​:
20​:38 < [Coke]> rakudo​: say "a" ~~ m​:nth(Mu)/a/
20​:38 <+p6eval> rakudo ebd4d8​: OUTPUT«=> <a>â�¤â�¤Â»

Tests needed.

--
Will "Coke" Coleda

@p6rt
Copy link
Author

p6rt commented Oct 1, 2011

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

@p6rt
Copy link
Author

p6rt commented Mar 4, 2012

From @moritz

Now that :nth is implemented again, we're back to infinite recursion.

@p6rt
Copy link
Author

p6rt commented Jul 15, 2012

From @bbkr

Warning​: This should no longer match!

In 2012.06-93-gee86a54 infinite recursion is gone,
and nth() param requires at least Any.

$ ./perl6 -e 'say "a" ~~ m​:nth(Mu)/a/'
Nominal type check failed for parameter '$nth'; expected Any but got Mu instead
  in method match at src/gen/CORE.setting​:3923
  in block <anon> at -e​:1

On IRC jnthn++ confirmed this to be desired behavior.

jnthn bbkr​: Infinite recursion was wrong for sure. 22​:02
jnthn bbkr​: Not accepting Mu is fine.

So it is still testneeded but now runtime error is expected.

@p6rt
Copy link
Author

p6rt commented Jul 15, 2012

From @bbkr

Test in

Raku/roast@9973e0d457

@p6rt
Copy link
Author

p6rt commented Jul 15, 2012

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

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

No branches or pull requests

1 participant