A Fading Gem

Recently there has been some talk about how Ruby is a dying language. I am not a Ruby expert but I played with it a few months back so feel 100% qualified to comment, in fact I am a practical expert!

A dying language is not a precise term, it can mean many things:

  1. Contractors can’t get work using the language anymore.
  2. A new language is trying to grab users and attempting to position the old language as one dying and needs to moved away from. Trigger that FOMO.
  3. The number of people attempting to learning the language is declining.
  4. The actual number of users is actually declining.

I am sure you can think of a few other reasons. Unless you are a contractor then reasons 3 or 4 are danger signals but also hardest to actually get real data about.

Don’t panic! Programming languages take a really long time to die.

Ruby shot to fame and fortune due to the popularity of Ruby on Rails. Ruby is not just Rails, it is a perfectly good dynamically typed language. When I spent a few weeks with it I got the impression it was just starting to mature!

By that I means holes are starting to be filled. Long term dynamically typed languages usually need a JIT, by long term I am thinking decades. It enables language implementation of more CPU intensive applications, that is you don’t have to call out to libraries so often. This is great for library developers.

With a JIT pressure mounts for optional typing to eek out more performance along with making certain types of programming easier. Types ease maintenance and let libraries evolve with ease. I admit to liking the idea of gradual typing when used in the context of exploratory/learning based programming.

Where Ruby along with Python and other seem to not have such a good story is deployment outside of servers. There are exe generators for Linux/Mac/Windows but they tend to not support the mobile platforms. This is further compounded by WASM slowly starting to become something that needs targeting.

These exe generators tend to package up the interpreter with the source files. I don’t mind this approach but I would really rather see something closer to static compilation with escape hatches when needed. While I am on the topic being easily to be able to “cross compile” using the exe generators is something that needs solving as Ruby matures.

The small amount of time I spent with gave me some confidence that the language is progressing on some of these fronts, so my feeling is Ruby is slowly maturing, yes it’s fast growth phase is probably over but that doesn’t make it a dead language. It seems to have enough people to continue to evolve at a steady rate over the next decade or two.

You may say why are things like exe generators important but why when I spend all my time doing Rails?

On one hand you could argue that Ruby is strong in one area but not in others so to continue to grow it need to make it a joy to use in other domains. This may be indie game dev or iPhone apps or well something innovative that I can’t currently identify because it is 5 years off being mainstream. It’s by having a diverse set of users (fingers in many pies) that it will catch the next growth area allowing continued development of Ruby for all users.

A second argument is don’t give people a reason to leave the language. If Ruby lets you easily create an SDL or Vulkan application and then easily generate the Android version then the Rails dev who want to experiment in a different area of computing has not reason to leave the Ruby eco system.

I personally think Ruby is maturing in that direction just I am not sure the rate at which it is happening.

Finally think about python. It started as an automate things that you would have done in a shell script or Perl. Gained some momentum because it was very easy to embed inside other applications and finally grew massively in the AI/data analysis because of it’s initial simplicity and the ease at which it could hook up to native libraries.

At some point Python entered education, again due to simplicity, and gained wide spread acceptance there at all levels.

The story of python is it was matured enough in terms of infrastructure that people were able to take it in directions not entirely expected. In year 2000 I could not have predicted the future large scale use cases for Python but I could have identified the strong points that allowed it to achieve the success it has had.

In summary: I don’t thing Ruby is dying, even if I have barely used it :) I do think it is starting to mature in terms of tooling around the language. If I had a smidgen of control over the language I would be advocating increasing the range of use cases that ruby works well for, either via targeting niches or attempt to create broad general purpose tooling.

Another summary is I really don’t have a clue what I am talking about!


875 Words

2020-09-23 19:49 +0000