Clear distances passed into _getRawObjects

Add comment suggested by Naomi
Use $near distances as lowest-priority sort key

Previously, $near was only used in the absence of a sort specifier; now,
it's also used as a tie-breaker when there is a sort specifier. (Tested:
this matches MongoDB.)
NOTES update.
Refactor selector-vs-modifier/projection code

Now they are methods on a compiled Matcher rather than doing their own
operator parsing from scratch. This means less work is happening for
each oplog entry, and it also localizes knowledge about selector
parsing.
Throw on missing distance
set arrayIndex in most places

(not $near or $elemMatch yet)
rename args in andSomeMatchers
remove random type tag in test
JSON -> EJSON in test
Refactor: optionify LocalCollection._modify arg
Cleanup/modernization of modify.js
clean up findModTarget

convert arguments to options
Implement 'a.$.b' modifier

Does not yet work with $near or $elemMatch
Implement '$' update for $near
Implement '$' update for $elemMatch
Merge branch 'minimongo-array-updates' into devel

Actually implement updating field 'x.$.y'! Also some related cleanups.