10/24時点
以前見た時の違って、浮動小数点の演算が出来るようになっていました。また、今月の上旬あたりからGenericsが使えるようになっています。
IronRuby Pre-Alpha (1.0.0.0) on .NET 2.0.50727.832 Copyright (c) Microsoft Corporation. All rights reserved. >>> require "mscorlib" => true >>> Int32List = System::Collections::Generic::List.of(System::Int32) => List`1 >>> list = Int32List.new => [] >>> list.add 1 => nil >>> list.add 2 => nil >>> list.count => 2 >>> list.each { |x| print x + 10, "\n" } 11 12 => [1, 2]
ってな感じ。
Genericsの型指定で、
List.of(Int32)
というようにofを使うのが面白いですね。