Moves instanceOf function to object prototype

This is so that all non-null and non-undefined objects in the system can
have instanceOf called against them meaning we do not have to check
for the method before we can validate a certain class or interface.

Specifically, we can call instanceOf on strings, numbers, objects,
arrays and booleans without error. All except objects are guaranteed to
return false as they cannot be instances of Class, user defined classes
or interfaces.