Permalink
Commits on Apr 23, 2012
  1. Merge pull request #566 from roryokane/patch-1

    jashkenas committed Apr 23, 2012
    in sortedIndex test, rename variables to prevent confusion
  2. Merge pull request #567 from shama/patch-typo

    braddunbar committed Apr 23, 2012
    A few typo fixes
  3. typo fixes

    shama committed Apr 23, 2012
Commits on Apr 22, 2012
  1. in sortedIndex test, rename variables to prevent confusion

    roryokane committed Apr 22, 2012
    I was confused when I read the second part of the test. The variable name was index2, and "30 should be inserted at index 2". But then I looked a few lines up, and saw that index's number "should be inserted at index 3". I had thought that the '2' at the end of 'index2' meant something it didn't. This renaming prevents that confusion.
    
    This change highlights the repetition in this test. It is possible that a good next step would be to refactor the testing of these two numbers into an each loop. Or perhaps that would make the test unnecessarily complicated. I am not confident enough to make that call, so I'll leave it as it is.
Commits on Apr 19, 2012
  1. comments and style tweaks

    jashkenas committed Apr 19, 2012
  2. Merge pull request #563 from kevinoid/sorted-index-spec

    jashkenas committed Apr 19, 2012
    Tighten specification for _.sortedIndex
  3. Merge pull request #562 from colinta/master

    jashkenas committed Apr 19, 2012
    One last addition...
  4. Add test for tightened sortedIndex specification

    kevinoid committed Apr 19, 2012
    Test that the lowest index, rather than any index, at which the element
    should be inserted to maintain sorted order is returned.
    
    Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
  5. Tighten specification for _.sortedIndex

    kevinoid committed Apr 19, 2012
    sortedIndex should specify that it returns the lowest index at which an
    item may be inserted to maintain sorted order, rather than any index
    which satisfies this property, in order to provide easier use
    maintaining a sorted list of unique elements.
    
    For example, with the previous specification, the following behavior is
    possible:
    
    _.sortedIndex([10, 20, 30, 40], 30)
    => 3
    
    To accommodate this behavior users would have to check both array[si]
    and array[si-1] (when si > 0) before inserting to ensure uniqueness, or
    to examine the underscore.js implementation and rely on the
    implementation not changing.
    
    Note:  This specification change does not require any changes to the
    code.
    
    Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
Commits on Apr 18, 2012
  1. Merge pull request #560 from braddunbar/interpolate-null

    jashkenas committed Apr 18, 2012
    Fix #556 - interpolate coerces null/undefined to ''.
Commits on Apr 10, 2012
Commits on Apr 9, 2012
  1. Underscore.js 1.3.2

    jashkenas committed Apr 9, 2012
  2. resolving merge

    jashkenas committed Apr 9, 2012
Commits on Apr 6, 2012
  1. Merge pull request #542 from braddunbar/template-concat

    jashkenas committed Apr 6, 2012
    _.template Uses Concatenation
  2. Correct errant newlines.

    braddunbar committed Apr 6, 2012
Commits on Apr 4, 2012
  1. Merge pull request #540 from braddunbar/template-varname

    braddunbar committed Apr 4, 2012
    Add variable to _.templateSettings.
  2. Tweak variable names. Update docs.

    braddunbar committed Apr 4, 2012
    * Restore template.source.
    * Use variable instead of varname.
    * Use text for template input.
    * Include settings in documentation.
Commits on Apr 3, 2012
  1. Add varname to _.templateSettings.

    braddunbar committed Apr 3, 2012
    * Leave out the with statement when using varname.
    * Rename source to compiled.
    * Comments, comments, comments.
  2. removing added speed test

    jashkenas committed Apr 3, 2012
  3. Merge pull request #539 from fawek/_.shuffle

    jashkenas committed Apr 3, 2012
    Remove the unnecessary branch in _.shuffle()
  4. Remove the unnecessary branch in _.shuffle()

    Jakub Wieczorek
    Jakub Wieczorek committed Apr 3, 2012
    The non-zero case works properly for 0 as well.
Commits on Apr 2, 2012
  1. Merge pull request #500 from bryanwoods/master

    jashkenas committed Apr 2, 2012
    Aliases `_.take()` to `_.first()` and `_.head()`