summaryrefslogtreecommitdiffstats
path: root/xpcom/reflect/xptinfo
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-12 05:35:29 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-12 05:35:29 +0000
commit59203c63bb777a3bacec32fb8830fba33540e809 (patch)
tree58298e711c0ff0575818c30485b44a2f21bf28a0 /xpcom/reflect/xptinfo
parentAdding upstream version 126.0.1. (diff)
downloadfirefox-59203c63bb777a3bacec32fb8830fba33540e809.tar.xz
firefox-59203c63bb777a3bacec32fb8830fba33540e809.zip
Adding upstream version 127.0.upstream/127.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'xpcom/reflect/xptinfo')
-rw-r--r--xpcom/reflect/xptinfo/xptcodegen.py21
1 files changed, 1 insertions, 20 deletions
diff --git a/xpcom/reflect/xptinfo/xptcodegen.py b/xpcom/reflect/xptinfo/xptcodegen.py
index 9dd54a6f07..67860ca1f2 100644
--- a/xpcom/reflect/xptinfo/xptcodegen.py
+++ b/xpcom/reflect/xptinfo/xptcodegen.py
@@ -330,30 +330,11 @@ def link_to_cpp(interfaces, fd, header_fd):
)
)
- def is_type_reflectable(type):
- # All native types end up getting tagged as void*, or as wrapper types around void*
- if type["tag"] == "TD_VOID":
- return False
- if type["tag"] in ("TD_ARRAY", "TD_LEGACY_ARRAY"):
- return is_type_reflectable(type["element"])
- return True
-
- def is_method_reflectable(method):
- if "hidden" in method["flags"]:
- return False
-
- for param in method["params"]:
- # Reflected methods can't use non-reflectable types.
- if not is_type_reflectable(param["type"]):
- return False
-
- return True
-
def lower_method(method, ifacename, builtinclass):
methodname = "%s::%s" % (ifacename, method["name"])
isSymbol = "symbol" in method["flags"]
- reflectable = is_method_reflectable(method)
+ reflectable = "hidden" not in method["flags"]
if not reflectable and builtinclass:
# Hide the parameters of methods that can't be called from JS and