Support RLMObject and RLMArray predicates comparing on object identity

Also adds more tests and fixes a few issues with our initial support for keypaths.

@jpsim @bmunkholm @kneth 
No, it's called `add_link_contraint_to_query` (no s).