I encountered, but have not completely isolated, a problem which seems to indicate that isExtensible is not sufficient for purpose of detecting whether a hidden record can be added to a key of a WeakMap. Making the following change solved the problem I encountered:
https://github.com/drses/weak-map/commit/7a89a00bc11b50626db0bdc824c32cd83e5d79e0 However, I have not managed to create a test that reproduces the problem on my own machine, with the same versions of Node.js and npm as are seen on TravisCI where I encountered the problem. The problem may arise only if the weak map shim is executed multiple times, which can occur and is furthermore expected with Node.js and npm when there are version mismatches between dependencies. On an unrelated note, WeakMap in Subversion is now coupled with SES’s problem/fix system, which are changes I can’t bring to bear with a stand alone WeakMap shim. The only viable solution may be to manually port all subsequent patches. Alternately, it might be necessary for WeakMap to entrain all of SES and just pick out the WeakMap part at run-time, which limits its viability. However, I’m keenly aware these are issues that are probably out of scope for the Caja project. Kris Kowal -- --- You received this message because you are subscribed to the Google Groups "Google Caja Discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
