<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>CHANGES</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -11,6 +11,9 @@ those; the ones with the same name as prototype extensions have the
 same spec as those in the Prototype library; and there's a few odds
 and ends such as String#capitalize.
 
+The methods are documented in lib/collections.js, and speced (for
+further documentation, as well as testing) in spec/*.js.
+
 License
 =======
 Copyright 2007-2008 by Oliver Steele.  Available under the MIT License.</diff>
      <filename>README</filename>
    </modified>
    <modified>
      <diff>@@ -220,10 +220,28 @@ define(Array, 'partitionBy', function(fn) {
 
 })();
 
+
 /*
- * Monadic Arrays
+ * Global array functions
  */
 
+if (!Array.slice) { // mozilla already defines this
+    Array.slice = (function() {
+        var slice = Array.prototype.slice;
+        return function(array) {
+            return slice.apply(array, slice.call(arguments, 1));
+        };
+    })();
+}
+
+/* Return a function that returns the value of the `propertyName`
+ * property of its first argument. */
+function pluck(propertyName) {
+    return function(object) {
+        return object[propertyName];
+    }
+}
+
 /** Return an array.  Identity for arrays; same as monadic `return`
   * for other values.
   */</diff>
      <filename>lib/collections.js</filename>
    </modified>
    <modified>
      <diff>@@ -191,6 +191,27 @@ describe('Array.partitionBy', {
     }
 });
 
+describe('Array.slice', {
+    'should slice': function() {
+        var array = [1,2,10,11,22];
+        value_of(Array.slice(array, 0).join(',')).should_be([1,2,10,11,22].join(','));
+        value_of(Array.slice(array, 1).join(',')).should_be([2,10,11,22].join(','));
+        value_of(Array.slice(array, 1, 3).join(',')).should_be([2,10].join(','));
+    }
+});
+
+describe('pluck', {
+    'should work with map': function() {
+        value_of([{x:1,y:2}, {x:3,y:4}].map(pluck('x'))).should_be([1,3]);
+    },
+    'should work with select': function() {
+        var array = [{x:1,y:2}, {z:3,w:4}];
+        var result = array.select(pluck('x'));
+        value_of(result.length).should_be(1);
+        value_of(result[0]).should_be(array[0]);
+    }
+});
+
 describe('Array.toList', {
     'should be identity on arrays': function() {
         value_of(Array.toList([1,2])).should_be([1,2]);</diff>
      <filename>specs/array-specs.js</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>95224586cb58b259b6291cf9733e49fab62e13a4</id>
    </parent>
  </parents>
  <author>
    <name>Oliver Steele</name>
    <email>steele@osteele.com</email>
  </author>
  <url>http://github.com/osteele/collections-js/commit/b1a67c4f8188e14eb4d6c0d89fdc09910ec0c7fd</url>
  <id>b1a67c4f8188e14eb4d6c0d89fdc09910ec0c7fd</id>
  <committed-date>2008-04-18T20:11:38-07:00</committed-date>
  <authored-date>2008-04-18T20:11:38-07:00</authored-date>
  <message>add Array.slice, global pluck</message>
  <tree>152e3eb0893df346a40645a497f93cfd73b46f68</tree>
  <committer>
    <name>Oliver Steele</name>
    <email>steele@osteele.com</email>
  </committer>
</commit>
