General

Profile

alexeymuranov (Alexey Muranov)

  • Login: alexeymuranov
  • Registered on: 07/30/2011
  • Last sign in: 04/14/2016

Issues

open closed Total
Assigned issues 0 0 0
Reported issues 15 30 45

Activity

02/07/2016

08:53 PM Ruby Feature #12057: Allow methods with `yield` to be called without a block
Or maybe not an iterator but a delimited continuation?
Probably the following behavior is more natural:
~~~ruby
def f
['a', 'b', 'c'].each do |c|
puts yield c
end
return 'd'
end
c, v = f
puts v # : a
c, v = c....
alexeymuranov (Alexey Muranov)
08:23 PM Ruby Feature #12057 (Open): Allow methods with `yield` to be called without a block
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.
...
alexeymuranov (Alexey Muranov)

12/19/2015

11:43 AM Ruby Feature #5123: Alias Hash 1.9 as OrderedHash
I have just stumbled upon this: the [Immutable collections for JavaScript](http://facebook.github.io/immutable-js/) has both `Map` and [`OrderedMap`](http://facebook.github.io/immutable-js/docs/#/OrderedMap).
One more: in Haskell, the...
alexeymuranov (Alexey Muranov)

12/10/2015

01:53 PM Ruby Feature #5478: Add syntax to import Set into core
Another syntax idea:
```ruby
{|1,2,3|}
```
alexeymuranov (Alexey Muranov)

11/20/2014

05:20 PM Ruby Feature #10528: Allow line breaks instead of commas in arrays, hashes, argument lists, etc.
I forgot to mention other usual cases when lines should be implicitly continued: after a dot, after an operator symbol, etc. alexeymuranov (Alexey Muranov)
11:14 AM Ruby Feature #10528 (Open): Allow line breaks instead of commas in arrays, hashes, argument lists, etc.
Since the seemingly reasonable proposal #8956 has been rejected because it "diverged so far from the original", i will dare to propose another version here.
I suggest to automatically convert line breaks inside parentheses `(...)`, in...
alexeymuranov (Alexey Muranov)
11:15 AM Ruby Feature #8956: Allow hash members delimited by \n inside of {}
I have proposed another version: #10528. alexeymuranov (Alexey Muranov)

07/25/2014

09:59 AM Ruby Feature #5478: Add syntax to import Set into core
It has not been mentioned in this thread yet that in Python it is done like this:
```python
empty_set = set() # => set([])
some_set = {1, 1, 2, 2, 3, 4} # => set([1, 2, 3, 4])
```
Python [has no literal for the e...
alexeymuranov (Alexey Muranov)

06/30/2014

01:45 PM Ruby Feature #6806: Support functional programming: forbid instance/class variables for ModuleName::method_name, allow for ModuleName.method_name
I meant that a function called like `Math::sin` would be required to return same values (for same arguments) every time. Maybe i did not explain this well. `Foo.bar`, on the other hand, would not have this restriction.
Same could be...
alexeymuranov (Alexey Muranov)
01:31 PM Ruby Feature #6806: Support functional programming: forbid instance/class variables for ModuleName::method_name, allow for ModuleName.method_name
Besides functional programming, IMO this would support [command–query separation](https://en.wikipedia.org/wiki/Command–query_separation). alexeymuranov (Alexey Muranov)

Also available in: Atom