[#73707] [Ruby trunk Misc#12004] Code of Conduct — hanmac@...
Issue #12004 has been updated by Hans Mackowiak.
3 messages
2016/02/05
[#73730] [Ruby trunk Feature#12034] RegExp does not respect file encoding directive — nobu@...
Issue #12034 has been updated by Nobuyoshi Nakada.
3 messages
2016/02/07
[#73746] [Ruby trunk Feature#12034] RegExp does not respect file encoding directive — nobu@...
Issue #12034 has been updated by Nobuyoshi Nakada.
3 messages
2016/02/09
[#73919] [Ruby trunk Feature#11262] Make more objects behave like "Functions" — Ruby-Lang@...
Issue #11262 has been updated by J旦rg W Mittag.
3 messages
2016/02/22
[#74019] [Ruby trunk Bug#12103][Rejected] ruby process hangs while executing regular expression. — duerst@...
Issue #12103 has been updated by Martin D端rst.
3 messages
2016/02/27
[ruby-core:73735] [CommonRuby Feature#12057] Allow methods with `yield` to be called without a block
From:
alexey.muranov@...
Date:
2016-02-07 20:23:44 UTC
List:
ruby-core #73735
Issue #12057 has been reported by Alexey Muranov. ---------------------------------------- Feature #12057: Allow methods with `yield` to be called without a block https://bugs.ruby-lang.org/issues/12057 * Author: Alexey Muranov * Status: Open * Priority: Normal * Assignee: ---------------------------------------- Trying to figure out how `yield` works in Python, i had the following idea. Allow a method with `yield` to be called without a block. When a method encounters `yield`, if no block is given, the method returns an `Enumerator` object. ~~~ruby def f yield 'a' yield 'b' end e = f puts e.next # => a puts e.next # => b ~~~ It seems that this is what `yield` in Python does, but in Python a function with `yield` cannot take a block. Why not to have both? -- https://bugs.ruby-lang.org/ Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe> <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>