Bug 1348099 part 3 - Fix the codegen so the methods for clearing cached attribute values are not unforgeable. r?bz
Current codegen list the methods for clearing cached attribute values in both
chrome only unforgeable methods and chrome only normal methods, but they should
exist only in the normal ones.
MozReview-Commit-ID: Il2JvCLZ2v3
--- a/dom/bindings/Codegen.py
+++ b/dom/bindings/Codegen.py
@@ -2564,17 +2564,17 @@ class MethodDefiner(PropertyDefiner):
self.chrome.append({
"name": '_create',
"nativeName": ("%s::_Create" % descriptor.name),
"methodInfo": False,
"length": 2,
"flags": "0",
"condition": MemberCondition()
})
- else:
+ elif not unforgeable:
for m in clearableCachedAttrs(descriptor):
attrName = MakeNativeName(m.identifier.name)
self.chrome.append({
"name": "_clearCached%sValue" % attrName,
"nativeName": MakeJSImplClearCachedValueNativeName(m),
"methodInfo": False,
"length": "0",
"flags": "0",