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 do do ;" errors when "say do do;" succeeds #2915

Closed
p6rt opened this issue Oct 12, 2012 · 5 comments
Closed

"say do do ;" errors when "say do do;" succeeds #2915

p6rt opened this issue Oct 12, 2012 · 5 comments

Comments

@p6rt
Copy link

p6rt commented Oct 12, 2012

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

Searchable as RT115230$

@p6rt
Copy link
Author

p6rt commented Oct 12, 2012

From @japhb

TimToady++ pointed out one side of an interesting edge case in keyword parsing​:

<TimToady> [Coke]​: note that most keywords in p6 will win under LTM because they tend to include a trailing whitespace.
<TimToady> r​: my \do = 42; say do do;
<p6eval> rakudo 547fcb​: OUTPUT«42␤»
<japhb_> r​: my \do = 42; say do do ;
<p6eval> rakudo 547fcb​: OUTPUT«===SORRY!===␤Error while compiling block : Error while compiling op call​: Error while compiling block : Error while compiling block : Can only use get_how on a SixModelObject␤»
<jnthn> whoa...
<jnthn> japhb_​: That one'd want reporting.

-'f

@p6rt
Copy link
Author

p6rt commented Mar 29, 2015

From @usev6

As a status update​: The second evaluation still errors, but with a different error message. (IMHO the error message makes it clearer that the second 'do' is parsed as a keyword.)

$ perl6 -e 'my \do = 42; say do do;'
42

$ perl6 -e 'my \do = 42; say do do ;'
===SORRY!=== Error while compiling -e
Missing block or statement
at -e​:1
------> my \do = 42; say do do⏏ ;

1 similar comment
@p6rt
Copy link
Author

p6rt commented Mar 29, 2015

From @usev6

As a status update​: The second evaluation still errors, but with a different error message. (IMHO the error message makes it clearer that the second 'do' is parsed as a keyword.)

$ perl6 -e 'my \do = 42; say do do;'
42

$ perl6 -e 'my \do = 42; say do do ;'
===SORRY!=== Error while compiling -e
Missing block or statement
at -e​:1
------> my \do = 42; say do do⏏ ;

@p6rt
Copy link
Author

p6rt commented Mar 29, 2015

@usev6 - Status changed from 'new' to 'open'

@p6rt p6rt closed this as completed Apr 7, 2016
@p6rt
Copy link
Author

p6rt commented Apr 7, 2016

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant