vendor/optional/lodash-0.3.2.js
function toArray(collection) {
    if (!collection) {
      return [];
    }
    if (toString.call(collection.toArray) == funcClass) {
      return collection.toArray();
    }
    var length = collection.length;
    if (length === length >>> 0) {
      return slice.call(collection);
    }
    return values(collection);
  }
function toArray(collection) {
    if (!collection) {
      return [];
    }
    if (toString.call(collection.toArray) == funcClass) {
      return collection.toArray();
    }
    var length = collection.length;
    if (length === length >>> 0) {
      return slice.call(collection);
    }
    return values(collection);
  }
function toArray ( collection ) { if ( ! collection ) { return [ ] ; } if ( toString . call ( collection . toArray ) == funcClass ) { return collection . toArray ( ) ; } var length = collection . length ; if ( length === length >>> 0 ) { return slice . call ( collection ) ; } return values ( collection ) ; }
Converts the `collection`, into an array. Useful for converting the
`arguments` object.

@static
@memberOf _
@category Collections
@param {Array|Object} collection The collection to convert.
@returns {Array} Returns the new converted array.
@example

(function() { return _.toArray(arguments).slice(1); })(1, 2, 3, 4);
// => [2, 3, 4]
Converts the collection into an array . Useful for converting the arguments object .