Created attachment 545480 [details] [diff] [review]
Bug 670702 has evidence that some non-cross compartment JSWrappers have pointers outside their compartment. Blake confirms that this is not expected. This patch adds some additional opt-mode assertions to try and narrow down the code creating these pointers.
I'm sorry about how gross the check is. Unfortunately, we're not allowed to get the compartment for static strings, since they're not part of the GC heap.
Created attachment 545485 [details] [diff] [review]
Since the priv field can't be a string, this patch is shorter.