Stuart Halloway created JRUBY-6264: -------------------------------------- Summary: RubyArray.toArray does not conform to Collection API Key: JRUBY-6264 URL: https://jira.codehaus.org/browse/JRUBY-6264 Project: JRuby Issue Type: Bug Reporter: Stuart Halloway Assignee: Thomas E Enebo
It appears to have two problems: * does not append a null after the last element, when the array passed in is big enough to allow this. (Other parts of the codebase, e.g. GenericMap.toArray, do this correctly.) * allocates unnecessarily by basing the decision to allocate a new array on realLength, not realLength - begin. There may be some subtlety about the second point that I am missing, as the problem is repeated in the no-arg version, which also allocates an unnecessarily large array. If folks agree with my assessment I can provide a patch (once I get JRuby building, which it does not want to do out of the box). -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email