A simple solution would be to just compare constructor names. This will at least catch cases like: Object.shallowEqual([], {}); class A {}; class B extends A {}; Object.shallowEqual(new A, new B);
Created attachment 288585 [details] [Patch] Proposed Fix
<rdar://problem/28262106>
Comment on attachment 288585 [details] [Patch] Proposed Fix View in context: https://bugs.webkit.org/attachment.cgi?id=288585&action=review r=me > Source/WebInspectorUI/UserInterface/Base/Utilities.js:63 > + if (a.constructor !== b.constructor) > return false; We discussed an alternative checking (__proto__ / Object.getPrototypeOf). I'm fine with either because we shouldn't be modifying object instance __proto__ properties anywhere.
Comment on attachment 288585 [details] [Patch] Proposed Fix Clearing flags on attachment: 288585 Committed r205815: <http://trac.webkit.org/changeset/205815>
All reviewed patches have been landed. Closing bug.