From: shevegen@... Date: 2019-06-13T11:43:46+00:00 Subject: [ruby-core:93105] [Ruby trunk Feature#15799] pipeline operator Issue #15799 has been updated by shevegen (Robert A. Heiler). I assume matz approved it. I don't think it is good to want to reason against a change since the decision making is not a community-decision in general. As for the feature itself - I do not like the syntax, but as is the case with other changes, if I don't have to use it I don't really mind. ;) Otherwise I agree with Benoit's comment in regards to syntax; I don't necessarily agree on the other implied statement. I actually can see some reason for the pipeline, aside from elixir - it may look a bit more natural purely from when one can want to avoid using the "." (dot). That does not mean that I like the syntax but I can understand it a bit. I sort of infer indirectly, though. There is, however had, one thing that absolutely should happen - please consider adding some documentation and comments to explain what this feature is doing or why it was added. I understand that ruby kaigi was a driving factor here, but keep in mind that not everyone was at ruby kaigi; lots of folks may not know what was discussed at kaigi, so it would be really helpful if it could be commented what it does or what the discussion was about - like developer meetings where short summaries are provided too. No worries if this takes a while, but please don't forget it - right now I, for example, don't really know what the feature is really doing. I assume it is partially inspired by elixir but I may be wrong too - right now we just don't quite know. Or at the least I guess folks outside japan perhaps. I don't mind the decision making process in ruby at all, different to benoit perhaps :P - but I think documentation, comments etc... is an area where ruby should get better in general. The more, and better, documentation/explanation is given to ruby users, the better it will be for them to work with ruby in general, in particular when it comes to changes. There will probably be blog posts about this eventually, but the folks who write the blog posts will probably also appreciate as much information as possible. Thanks. ---------------------------------------- Feature #15799: pipeline operator https://bugs.ruby-lang.org/issues/15799#change-78530 * Author: nobu (Nobuyoshi Nakada) * Status: Closed * Priority: Normal * Assignee: * Target version: ---------------------------------------- Implemented the pipeline operator `|>`, a topic of "ruby committers vs the world" in RubyKaigi 2019. Also a casual idea of rightward assignment. ```ruby 1.. |> take 10 |> map {|e| e*2} |> (x) p x #=> [2, 4, 6, 8, 10, 12, 14, 16, 18, 20] ``` https://github.com/nobu/ruby/tree/feature/pipeline -- https://bugs.ruby-lang.org/ Unsubscribe: