From: mame@ruby-lang.org
To: ruby-core@ruby-lang.org
Subject: [ruby-core:103510] [Ruby master Feature#17398] SyntaxError in endless method
Date: Mon, 19 Apr 2021 05:06:07 +0000 (UTC) [thread overview]
Message-ID: <redmine.journal-91609.20210419050606.710@ruby-lang.org> (raw)
In-Reply-To: redmine.issue-17398.20201216195217.710@ruby-lang.org
Issue #17398 has been updated by mame (Yusuke Endoh).
File allow-command-style-endless-method-def.patch added
I'm attaching an updated patch with a test.
----------------------------------------
Feature #17398: SyntaxError in endless method
https://bugs.ruby-lang.org/issues/17398#change-91609
* Author: zverok (Victor Shepelev)
* Status: Open
* Priority: Normal
----------------------------------------
This works:
```ruby
def foo() = puts("bar")
```
This does not:
```ruby
def foo() = puts "bar"
# ^ syntax error, unexpected string literal, expecting `do' or '{' or '('
```
Is this intentional or accidental? Not sure how it is reasoned.
---Files--------------------------------
allow-command-style-endless-method-def.patch (3.44 KB)
--
https://bugs.ruby-lang.org/
next prev parent reply other threads:[~2021-04-19 5:06 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-16 19:52 [ruby-core:101475] [Ruby master Bug#17398] SyntaxError in endless method zverok.offline
2020-12-17 0:49 ` [ruby-core:101482] " mame
2020-12-17 9:39 ` [ruby-core:101495] " zverok.offline
2020-12-17 13:52 ` [ruby-core:101496] " eregontp
2020-12-17 16:16 ` [ruby-core:101498] " halostatue
2020-12-18 1:58 ` [ruby-core:101503] " mame
2021-04-16 4:30 ` [ruby-core:103470] [Ruby master Feature#17398] " matz
2021-04-19 5:06 ` mame [this message]
2021-05-12 8:32 ` [ruby-core:103795] " matz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.ruby-lang.org/en/community/mailing-lists/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=redmine.journal-91609.20210419050606.710@ruby-lang.org \
--to=ruby-core@ruby-lang.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).