rubinius/rubinius — pull request #2161 by jamesotron (2013-02-15 04:16:30+00:00)
Title: Add symbols as resources to Process.(g|s)et_rlimit

This PR fixes #2112 by adding support for symbols as resource names to `Process.getrlimit` and `Process.setrlimit`. What follows is the commit message for the change:

As of Ruby 1.9 you can pass a symbol as the name of the resource you're
operating on instead of using the constant form. For example:

Process.getrlimit(:CORE)
=> [0, 9223372036854775807]

whereas traditionally one would have used:

Process.getrlimit(Process::RLIMIT_CORE)
=> [0, 9223372036854775807]

This commit adds spec coverage to both Process.getrlimit and
Process.setrlimit checking that the symbol is interpreted
correctly and that the correct ArgumentError is raised when passed
an invalid resource name.