Ruby Weekly is a weekly newsletter covering the latest Ruby and Rails news.

Ruby Gets An Official Spec: Heading To Become An ISO International Standard

By Peter Cooper / December 7, 2009

red-specs.pngIt's long been a bone of contention in the Ruby world that Ruby, as a programming language, doesn't have an official spec (though RubySpec has been a noble, community effort to build an executable specification for Ruby). Now, though, there's a draft, official Ruby specification available for you to check out- based on Ruby 1.8.7 (which some aren't happy about).

From the announcement:

For wider and more application of Ruby language, "Ruby Standardization Working Group" has been established under Information-technology Promotion Agency, Japan (IPA) to define the specification of Ruby language on Oct. 2008. Since then the WG has been drafting the specification of Ruby language.

As the first draft of Ruby language specification has just recently completed, we'd like to request users and developers of Ruby communities to review it.

By gathering review comments widely from you, we are going to improve the draft of Ruby language specification further. Then we will propose the improved draft to Japanese Industrial Standards Committee (JISC) to be JIS. After JIS for Ruby has been published, we will propose it to International Standardization Organization (ISO/IEC JTC1) to be International Standard.

Why now? In a ruby-core thread about the forthcoming standard, Shugo Maeda spills the beans:

In addition, one of reasons why we need open standard for Ruby is that the basic guideline for the government procurement in Japan require it. In that policy, we should refer to open standards instead of specific products for fair competition.

While the prospect of getting cushy government contracts is appealing to Japanese Rubyists, it could also start to play a role elsewhere as governments start to ride their own open standards/open source bandwagons.

Ultimately, this news isn't going to matter to the majority of Rubyists yet, but becoming an international standard will ultimately lend more legitimacy to a language that has been flagging in popularity lately. If you want to jump right to checking out the standard (available only as a PDF at the moment), click here.

Comments

  1. Jay Godse says:

    I was talking to a fellow who works for IBM on the J9 JVM. His biggest complaint about Ruby was that there was no spec. With a spec, there is a stronger possibility of getting IBM and other big software providers to come on board.

    Mazel-tov!

  2. Steven Hilton says:

    "... flagging in popularity lately..."

    Eh? Wha... ?!

  3. grant says:

    Some of us would prefer it if big software providers like IBM would stay the hell away, unless they are willing to provide funding and keep their noses out of things.

  4. mtkd says:

    Ruby is doing just fine without a spec*.

    *see HTML5

  5. chrisco says:

    Just curious, how can we verify/quantify the "language that has been flagging in popularity"? Also, what is/are the reason(s)? Thanks.

  6. Dave says:

    I second the request that you back up your "has been flagging in popularity lately" statement. What exactly is the basis for that statement?

  7. Jan Wedekind says:

    The danger I see here is that big corporations like Microsoft and IBM will try to stack the standardisation committee in order to hijack the development process. Members can stifle innovation, push patented technologies, and favour proprietary operating systems. Just think about C++, HTML5, OOXML, ...

  8. Nate says:

    Won't this prolong new features and the quick development of Ruby?

  9. Leon Katsnelson says:

    I am really surprised and disappointed by some of the comments. I love Ruby but Ruby community I don't quite get. What is with all that negativism and anti establishment? Oh, having a standard will slow Ruby down. Ruby as a language has been evolving at a snails pace. Next to nobody is using 1.9 and that took forever to come out. Big bad corporations will stack the committee. Is this really the biggest issue with Ruby or the fact that it has stalled in its rize in popularity a more pressing problem http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html?
    Personally, I am pleased as punch that Ruby is becoming an ISO standard. It means that one can use Ruby on large comemrcial projects and not just in a start-up or some skunk works project. This is a good thing in my book. Way to go Ruby!

  10. Beoran says:

    If you read the linked article, you'll see that these people, funded by a Japanese government agency, started their work over one year ago in Oct. 2008. THEN, Ruby 1.9.1 was not officially released yet, so their approach made perfect sense, at the time.

    I agree with the feeling that it would have been nice if they could use 1.9.1 as the base of the standard. However, it's a bit rough to ask them to throw away one year of work at this point of the game. It's a step too important to loose one more year over.

    Furthermore, on the commenting site, they have stated that the goal is to write a spec that is compatible both with 1.8.7 and 1.9.1. So, why don't you all read the specification and comment it? Once this spec is out the door, it will do a lot of good for the reputation and adoption of Ruby world wide! Then, we can move on to a 2.0 based spec in a couple of years time. All in all, I think this is great news!

  11. Shane says:

    "It means that one can use Ruby on large comemrcial projects".

    @Leon You are kidding yourself if you think Ruby (1.8.x or 1.9) isn't already used on large commercial projects. We've all been doing it for years without an ISO standard, certifications, someone declaring it 'enterprise ready' or any of that bullshit.

    "one of reasons why we need open standard for Ruby is that the basic guideline for the government procurement in Japan require it." -- Matz

    This is really just paperwork to keep 'the establishment' happy. The fear here, I think, is it will also attract entities (including developers) who wont understand or adopt the communities 'optimized for humans' mantra.

    Shane.

  12. Shane says:

    I attributed that quote to Matz, it was actually Shugo Maeda.

  13. Beoran says:

    @Shane

    I agree that this spec is also, to a degree, "paperwork for the establishment". But, I think that this is mostly a good thing! The ISO standard for Ruby will give us a very useful argument to convince the pointy haired bosses and the jobsworths to let us use Ruby.

    As for your fears that it will attract people who don't understand the spirit of Ruby,
    I think that is the price of popularity. I still think "the more the merrier". We use Ruby because it is fun and easy to use. Why should we be unhappy if more people start to use it? Surely, most of them will discover the spirit of Ruby, and enjoy it too.

    Furthermore, the Ruby ISO standard specifies what a Ruby implementation should be like. In this way, it *captures and protects* that "optimized for humans" idea. That's why I think that all in all, the ISO spec will be good for Ruby.

  14. Shane says:

    @Beoran

    Not my fears, just the impression I get from comments regarding specification discussion and before that the certification storm.

    The Rubyflow and Ycombinator posts last week also had a few mixed reactions:
    http://rubyflow.com/items/3110
    http://news.ycombinator.com/item?id=969623

    My $0.02 business as usual. MRI 1.9 is shiny and our tests would tell us if it wasn't.

  15. Beoran says:

    Well, I see your point, but I think that all this grumbling could be resolved easily if people would actually bother to *read the spec*, and *read the comments* on it, before complaining. If you read the document and the comments with accepted modifications, you'll see that by far and wide it's a very small, minimalistic, specification, which intends most existing Ruby implementations to be compatible with it.

    Sure, 1.9.1 is better than 1.8.7, but already, many comments with modifications to the specs have been accepted that ensure that MRI 1.9.1 as well as 1.8.7 will be compatible with the ISO Standard for Ruby. So, if there is any incompatibility with 1.9.1 in the spec that worries you, please contribute your own comments about it.

    My biggest concern now, is that I haven't seen many comments by people who are working on alternative Ruby implementations. Come on guys from JRuby, Rubinius, Maglev, etc, etc, let yourselves be heard!

  16. Hubert Łępicki says:

    The thing that I don't want to see is a spec keeping Ruby's evolution slowed down.

  17. Beoran says:

    @Hubert,

    I think you don't need to worry about that too much. This spec is mostly about making clear what Ruby is *now*. It's not at all about what Ruby will become in the future. It's very open for all sorts of extensions, so that it won't limit future modifications. Ruby will keep evolving in it's own way, and we'll update the standard from time to time so it keeps track of that evolution. Just like how are plenty of updated standards for, e.g. Fortran, even though that latter language has changed a lot through the ages.

Other Posts to Enjoy

Twitter Mentions