Project

General

Profile

Actions

Feature #9099

closed

Train emoji lambda operator

Added by Anonymous almost 11 years ago. Updated almost 11 years ago.

Status:
Feedback
Assignee:
-
Target version:
-
[ruby-core:58259]

Description

Matz mentioned during the 'Questions for Matz' section at RubyConf 2013 that he would like to the train emoji as an alternative to the stabby lambda operator.

I have implemented this and attached the patch.

Example code:

fn =


Files

train.patch (751 Bytes) train.patch Anonymous, 11/11/2013 07:05 AM
train.rb (47 Bytes) train.rb Anonymous, 11/11/2013 07:05 AM
0001-keywords-parse.y-keyord-lambda.patch (1.94 KB) 0001-keywords-parse.y-keyord-lambda.patch nobu (Nobuyoshi Nakada), 11/11/2013 05:25 PM

Updated by Anonymous almost 11 years ago

Redmine truncated the sample code due to the use of emoji, so I have attached a sample file instead.

Updated by duerst (Martin Dürst) almost 11 years ago

I had a look at https://bugs.ruby-lang.org/attachments/4038/train.patch.
Catching the 'train' emoji should be handled in the lexer, not in the
parser.

But first you have to make sure that the source file is actually UTF-8.

Also, when I looked at you first mail, I saw something that looked close
to a λ. Is that why this symbol was choosen?

Please note that there is nothing in the Unicode standard that says that
the symbol has to look like that, it can be a train looked at from the
front (see e.g. http://www.iemoji.com/view/emoji/847/places/train), or
any other representation of a train.

Also, as currently emoji characters are not that well supported, there
is quite some chance that the character gets rendered as a box or a
question mark, or not at all.

Regards, Martin.

On 2013/11/11 7:05, charliesome (Charlie Somerville) wrote:

Issue #9099 has been updated by charliesome (Charlie Somerville).

File train.rb added

Redmine truncated the sample code due to the use of emoji, so I have attached a sample file instead.

Feature #9099: Train emoji lambda operator
https://bugs.ruby-lang.org/issues/9099#change-42850

Author: charliesome (Charlie Somerville)
Status: Open
Priority: Normal
Assignee:
Category:
Target version:

Matz mentioned during the 'Questions for Matz' section at RubyConf 2013 that he would like to the train emoji as an alternative to the stabby lambda operator.

I have implemented this and attached the patch.

Example code:

fn =

Updated by matz (Yukihiro Matsumoto) almost 11 years ago

  • Category set to Joke
  • Status changed from Open to Feedback

Currently I have no idea to include any method not operator whose name contains non-ascii characters in the core libraries.

Matz.

Updated by duerst (Martin Dürst) almost 11 years ago

On 2013/11/11 17:52, matz (Yukihiro Matsumoto) wrote:

Issue #9099 has been updated by matz (Yukihiro Matsumoto).

Category set to Joke
Status changed from Open to Feedback

Currently I have no idea to include any method not operator whose name contains non-ascii characters in the core libraries.

This may imply that you have some ideas about implementing some
operators containing non-ascii characters. Can you confirm or deny?

Regards, Martin.

Matz.

Updated by matz (Yukihiro Matsumoto) almost 11 years ago

It's fundamentally denial.

Matz.

Updated by mame (Yusuke Endoh) almost 11 years ago

For those who cannot see it: U+1F685

http://www.unicode.org/charts/PDF/U1F680.pdf

--
Yusuke Endoh

Updated by Anonymous almost 11 years ago

@mame (Yusuke Endoh): OMG there are crazier people than me out there.

Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0Like0