Re:Ruby 3.0.0 RC1
by jeltz on Monday December 21, 2020 @10:37AM
(#25495844)
I would argue that is a good thing since it allows for performant access when you do not care about order. If you do not care about order you do usually not even have to allocate an array which means lower memory use. And how hard is it to write.
Ruby lacks polish in certain areas but this is not one. A d I would argue Python can be pretty tough in places too.
[ Parent
| on HN ]
Re:Ruby 3.0.0 RC1
by raverbashing on Monday December 21, 2020 @11:27AM
(#25496370)
Not that Dir, I mean as in .methods/.instance_methods (or dir(instance) in python )
I fixed it in my original comment
Then I understand your complaint even less. I almost never sort the output from methods and I do not think I have ever sorted the output from instance_methods during my over 10 years as a Ruby developer.
Re:Ruby 3.0.0 RC1
by raverbashing on Wednesday December 23, 2020 @05:19PM
(#25522933)
Python orders it. And when you want to look up a method by name you do a binary search by fact of being a sorted list