views:

267

answers:

10

I read somewhere that Ruby is the love-child of Smalltalk and LISP, with Miss Perl as the Nanny.

I have a lot of respect for Ruby's parents, but I'm not sure I like the influence Miss Perl had on the child. Specifically, I don't like the predefined variables: I need a cheat sheet to know what they mean. You could say "just don't use them". Well, I don't... but other people do. And when I download a plugin on the Web, I have no choice but to fetch my cheat-sheet if I ever need to go and touch the source code. I just wish they would remove those from the language itself.

Also, I think that Ruby is too much of a moving target. My code breaks on every new Ruby upgrade, even on minor releases. This is true also of Ruby on Rails and most Rails plugins I have worked with: they just change all the time, and nobody seems to care whether the changes break everything or not. IMHO, although I love a lot of things in Ruby, this lack of stability is almost a show-stopper.

Out of curiosity, what are the things you wish Ruby (and more generally the Ruby community) would improve? One suggestion per answer please, and +1 the ones you agree with.


Note: I have posted these 2 suggestions below, in order to see how many people agree with these. I don't know if it is considered "rude" to answer your own questions. I believe I read that it's ok, but maybe it depends on the type of question. Anyway, if it is frowned upon, let me know, and I will remove them.

Edit: I turned these into "community answers", I didn't know it was possible. Thanks for the advice Slartibartfast.

A: 

I wish they would get rid of the predefined variables: $!, $&, $+, etc.

MiniQuark
You could always include English.rb (which is part of the standard library) if you don't like the cryptic global variables. http://www.ruby-doc.org/core/files/lib/English_rb.html
Charles Roper
Interesting, thanks for the link. But my point is that as long as *anyone* uses those predefined variables, I'll still have to keep my cheat-sheet ready.
MiniQuark
+5  A: 

I wish people would consider backward compatibility between minor releases as an unbreakable rule when releasing a new language (or library or framework) version.

MiniQuark
Do you mean by "minor releases" changes between 1.8.x and 1.8.y? What kind of issues have you encountered?
Andrew Grimm
Yes, I mean changes between 1.8.x and 1.8.y. Those changes should be 100% painless, and they are not. Changes from 1.x to 1.y may involve some minor refactoring. Changes from 1. to 2. can break everything, that's ok.
MiniQuark
What kind of issues have you encountered changing between 1.8.x and 1.8.y?
Andrew Grimm
I don't know if this is what MiniQuark was referring to, but there were major changes between 1.8.6 and 1.8.7.
Andrew Grimm
+1  A: 

I'd appreciate being able to install ruby 1.9 as an RPM rather than having to use the source.

Andrew Grimm
Your distribution is responsible for providing you with packages. If they don't, a quick search will yield results for Ruby 1.9.1 RPMs. This has nothing to do with Ruby at all.
Nathan de Vries
@Nathan: I see what you mean. But the fact that it has nothing to do with the language itself doesn't mean that it's an irrelevant complaint about Ruby usage. For example, I could complain that Ruby developers are expensive: I am not complaining about the language itself, but about its environment.
MiniQuark
BTW, the "rubygems versus debian" war has to end.
MiniQuark
A: 

I would like to have support for static compile-time metaprogramming. The Converge Programming Language might be a good starting point.

Jörg W Mittag
+1  A: 

Getting rid of the artificial distinction between Modules and Classes would be nice.

Both Modules and Classes are Namespaces. Modules are also Mixins, while Classes aren't. Classes can also be instantiated while Modules can't. This distinction is unnecessary. Just get rid of Modules and allow Classes to be used as Mixins.

An example of a language where this works is Newspeak.

Jörg W Mittag
+1 Interesting. I use mixins in Python: they're simply classes. You just use inheritance to "include" them.
MiniQuark
Inheritance and mixins are different.
railsninja
A: 

Make Ruby completely Message Sending based, get rid of everything that is not a message send: local variables, global variables, instance variables, class hierarchy variables, constants, magic globals, magic constants, builtin operators, builtin keywords, even literals. See Self, Ioke or Newspeak for the incredible power and elegance this gains.

Jörg W Mittag
A: 

Replace the Mixin system with a Traits system.

Jörg W Mittag
+2  A: 

I wish that some of the lesser used modules of the standard library were documented.

Allyn
Fortunately, this is something you can fix without being a Ruby core contributor.
Sarah Mei
A: 

Replace Exceptions with a Common Lisp style Conditions system.

Jörg W Mittag
A: 

Make require-ing files less painful. Don't ask me how, but maybe have one file dedicated to knowing the paths involved and just get rid of the relative path crud from everything else.

Andrew Grimm