fix compile on osx
fix variable shadowing
avoid copies / constness / c++11 for loops
Merge branch 'big-pants' of github.com:mapbox/carmen-cache into big-pants
Merge branch 'big-pants' into spatialmatch

Conflicts:
	src/binding.cpp