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

if(something) is not treated as a sub call in Rakudo #374

Closed
p6rt opened this issue Oct 26, 2008 · 8 comments
Closed

if(something) is not treated as a sub call in Rakudo #374

p6rt opened this issue Oct 26, 2008 · 8 comments

Comments

@p6rt
Copy link

p6rt commented Oct 26, 2008

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

Searchable as RT60152$

@p6rt
Copy link
Author

p6rt commented Oct 26, 2008

From @masak

<moritz_> rakudo​: if(3 < 5) { say "yes" } # that should fail
<p6eval> rakudo 31963​: OUTPUT[yes␤]
<masak> moritz_​: another bug report :)
* masak reports
<moritz_> masak​: I just wanted to suggest just that ;)

Early experimentation indicates that this goes for unless, while,
until and given as well, and probably others I can't think of now.

@p6rt
Copy link
Author

p6rt commented Oct 27, 2008

From @pmichaud

On Sun, Oct 26, 2008 at 02​:47​:12PM -0700, Carl Mäsak wrote​:

<moritz_> rakudo​: if(3 < 5) { say "yes" } # that should fail

Early experimentation indicates that this goes for unless, while,
until and given as well, and probably others I can't think of now.

Just for the record (since the ticket doesn't explicitly mention it),
this should result in a syntax error because the block is a term
in operator position ("two terms in a row").

Pm

@p6rt
Copy link
Author

p6rt commented Oct 27, 2008

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

@p6rt
Copy link
Author

p6rt commented Feb 13, 2009

From @jnthn

On Mon Oct 27 11​:21​:57 2008, pmichaud wrote​:

On Sun, Oct 26, 2008 at 02​:47​:12PM -0700, Carl Mäsak wrote​:

<moritz_> rakudo​: if(3 < 5) { say "yes" } # that should fail

Early experimentation indicates that this goes for unless, while,
until and given as well, and probably others I can't think of now.

Just for the record (since the ticket doesn't explicitly mention it),
this should result in a syntax error because the block is a term
in operator position ("two terms in a row").

In STD.pm they just have​:

token statement_control​:if {
  <sym> :s

To turn on sigspace beyond that point. Once PGE implements that, it will
be pretty easy to fix this (and the others).

Thanks,

Jonathan

1 similar comment
@p6rt
Copy link
Author

p6rt commented Feb 13, 2009

From @jnthn

On Mon Oct 27 11​:21​:57 2008, pmichaud wrote​:

On Sun, Oct 26, 2008 at 02​:47​:12PM -0700, Carl Mäsak wrote​:

<moritz_> rakudo​: if(3 < 5) { say "yes" } # that should fail

Early experimentation indicates that this goes for unless, while,
until and given as well, and probably others I can't think of now.

Just for the record (since the ticket doesn't explicitly mention it),
this should result in a syntax error because the block is a term
in operator position ("two terms in a row").

In STD.pm they just have​:

token statement_control​:if {
  <sym> :s

To turn on sigspace beyond that point. Once PGE implements that, it will
be pretty easy to fix this (and the others).

Thanks,

Jonathan

@p6rt
Copy link
Author

p6rt commented Feb 28, 2009

From @pmichaud

On Mon Oct 27 11​:21​:57 2008, pmichaud wrote​:

On Sun, Oct 26, 2008 at 02​:47​:12PM -0700, Carl Mäsak wrote​:

<moritz_> rakudo​: if(3 < 5) { say "yes" } # that should fail

Early experimentation indicates that this goes for unless, while,
until and given as well, and probably others I can't think of now.

Just for the record (since the ticket doesn't explicitly mention it),
this should result in a syntax error because the block is a term
in operator position ("two terms in a row").

And as of 1e22a68, it does​:

  pmichaud@​orange​:~/rakudo$ ./perl6
  > if(3 < 5) { say 'yes' }
  Statement not terminated properly at line 1, near "{ say 'yes"
  > if (3 < 5) { say 'yes' }
  yes

Pm

1 similar comment
@p6rt
Copy link
Author

p6rt commented Feb 28, 2009

From @pmichaud

On Mon Oct 27 11​:21​:57 2008, pmichaud wrote​:

On Sun, Oct 26, 2008 at 02​:47​:12PM -0700, Carl Mäsak wrote​:

<moritz_> rakudo​: if(3 < 5) { say "yes" } # that should fail

Early experimentation indicates that this goes for unless, while,
until and given as well, and probably others I can't think of now.

Just for the record (since the ticket doesn't explicitly mention it),
this should result in a syntax error because the block is a term
in operator position ("two terms in a row").

And as of 1e22a68, it does​:

  pmichaud@​orange​:~/rakudo$ ./perl6
  > if(3 < 5) { say 'yes' }
  Statement not terminated properly at line 1, near "{ say 'yes"
  > if (3 < 5) { say 'yes' }
  yes

Pm

@p6rt
Copy link
Author

p6rt commented Feb 28, 2009

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

@p6rt p6rt closed this as completed Feb 28, 2009
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