const e=(t,n,r=`root`)=>{if(n==null)return n===t?{isIdentic:!0}:{isIdentic:!1,error:`Type mismatch at ${r}: expected ${n===null?`null`:`undefined`}, got ${t===null?`null`:typeof t}`};let i=Array.isArray(n)?`array`:typeof n,a=Array.isArray(t)?`array`:typeof t;if(i!==a)return{isIdentic:!1,error:`Type mismatch at ${r}: expected ${i}, got ${a}`};if(Array.isArray(n)&&Array.isArray(t)){if(n.length!==t.length)return{isIdentic:!1,error:`Array length mismatch at ${r}: expected ${n.length} elements, got ${t.length}`};for(let i=0;i<n.length;i++){let a=e(t[i],n[i],`${r}[${i}]`);if(!a.isIdentic)return a}return{isIdentic:!0}}if(typeof n==`object`&&typeof t==`object`&&n!==null&&t!==null){let i=Object.keys(n),a=Object.keys(t);if(i.length!==a.length)return{isIdentic:!1,error:`Object keys count mismatch at ${r}: expected ${i.length} keys, got ${a.length}`};for(let e=0;e<i.length;e++)if(i[e]!==a[e])return{isIdentic:!1,error:`Object keys mismatch at ${r}: expected key "${i[e]}" at position ${e}, got "${a[e]}"`};for(let a of i){let i=e(t[a],n[a],`${r}.${a}`);if(!i.isIdentic)return i}return{isIdentic:!0}}return{isIdentic:!0}};export{e};
//# sourceMappingURL=verifyIdenticObjectFormat.mjs.map