Object equivalence across jsd
"John J. Barton" <[email protected]>
| Newsgroups | gmane.comp.mozilla.devel.jsdebugger |
|---|---|
| Message-ID | <[email protected]> |
In a call to jsd.enumerateScripts Firebug has a line like this: if (script.functionObject.getWrappedValue() == fn) ... But it is never true. If I use: if (script.functionObject.getWrappedValue().name == fn.name) ... then I get a match and the script.tag is the one that was created with the function name fn.name. Since few function have "name" properties, my test, while more successful than Firebug's is not very useful. The objective is to retrieve the script matching a Function object. Any suggestions? Thanks, John.