class e extends WeakSet{#e;#s;constructor(e){super(),this.#e=new WeakSet,this.#s=e}add(e){return this.#e.delete(e),super.add(e)}delete(e){const s=this.has(e);return super.delete(e),this.#e.add(e),s}has(e){return!this.#e.has(e)&&(super.has(e)||this.#s.some((s=>s.has(e))))}}class s extends WeakMap{#t;#r;constructor(e){super(),this.#t=new WeakSet,this.#r=e.reverse()}delete(e){const s=this.has(e);return super.delete(e),this.#t.add(e),s}get(e){if(this.#t.has(e))return;if(super.has(e))return super.get(e);const s=this.#r.findIndex((s=>s.has(e)));return-1===s?void 0:this.#r[s].get(e)}has(e){return!this.#t.has(e)&&(super.has(e)||this.#r.some((s=>s.has(e))))}set(e,s){return this.#t.delete(e),super.set(e,s)}}exports.mergeWeakMaps=function(){for(var e=arguments.length,t=new Array(e),r=0;r