'use strict';varGetIntrinsic=require('../GetIntrinsic');var$TypeError=GetIntrinsic('%TypeError%');var$hasInstance=GetIntrinsic('Symbol.hasInstance',true);varCall=require('./Call');varGetMethod=require('./GetMethod');varIsCallable=require('./IsCallable');varOrdinaryHasInstance=require('./OrdinaryHasInstance');varToBoolean=require('./ToBoolean');varType=require('./Type');// https://www.ecma-international.org/ecma-262/6.0/#sec-instanceofoperatormodule.exports=functionInstanceofOperator(O,C){if(Type(O)!=='Object'){thrownew$TypeError('Assertion failed: Type(O) is not Object');}varinstOfHandler=$hasInstance?GetMethod(C,$hasInstance):void0;if(typeofinstOfHandler!=='undefined'){returnToBoolean(Call(instOfHandler,C,[O]));}if(!IsCallable(C)){thrownew$TypeError('`C` is not Callable');}returnOrdinaryHasInstance(C,O);};