throw error if the name given is hasOwnProperty
the name to test
the context in which the name is used, such as module or directive
throw error if the name given is hasOwnProperty