add CanGc as argument to methods in DissimilarOriginWindow, DocumentFragment, DocumentType, DOMRect, DOMRectReadOnly, DOMStringMap (#36395)

add CanGc as argument to methods in DissimilarOriginWindow,
DocumentFragment, DocumentType, DOMRect, DOMRectReadOnly, DOMStringMap

Testing: These changes do not require tests because they are a refactor.
Addressed part of https://github.com/servo/servo/issues/34573.

Signed-off-by: Yerkebulan Tulibergenov <yerkebulan@gmail.com>
This commit is contained in:
Yerkebulan Tulibergenov 2025-04-07 19:33:21 -07:00 committed by GitHub
parent 76e0b8ec06
commit 40655cc06c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 31 additions and 15 deletions

View file

@ -161,12 +161,16 @@ DOMInterfaces = {
'canGc': ['Close', 'CreateElement', 'CreateElementNS', 'ImportNode', 'SetTitle', 'Write', 'Writeln', 'CreateEvent', 'CreateRange', 'Open', 'Open_', 'CreateComment', 'CreateAttribute', 'CreateAttributeNS', 'CreateDocumentFragment', 'CreateTextNode', 'CreateCDATASection', 'CreateProcessingInstruction', 'Prepend', 'Append', 'ReplaceChildren', 'SetBgColor', 'SetFgColor', 'Fonts', 'ElementFromPoint', 'ElementsFromPoint', 'ExitFullscreen', 'CreateExpression', 'CreateNSResolver', 'Evaluate', 'StyleSheets', 'Implementation', 'GetElementsByTagName', 'GetElementsByTagNameNS', 'GetElementsByClassName', 'AdoptNode', 'CreateNodeIterator', 'SetBody', 'GetElementsByName', 'Images', 'Embeds', 'Plugins', 'Links', 'Forms', 'Scripts', 'Anchors', 'Applets', 'Children', 'GetSelection'],
},
'DissimilarOriginWindow': {
'canGc': ['Location']
},
'DocumentFragment': {
'canGc': ['Prepend', 'Append', 'ReplaceChildren']
'canGc': ['Prepend', 'Append', 'ReplaceChildren', 'Children']
},
'DocumentType': {
'canGc': ['Before', 'After', 'ReplaceWith']
'canGc': ['Before', 'After', 'Remove', 'ReplaceWith']
},
'DOMImplementation': {
@ -197,8 +201,16 @@ DOMInterfaces = {
'canGc': ['FromRect', 'FromQuad', 'GetBounds'],
},
'DOMRect': {
'canGc': ['FromRect'],
},
'DOMRectReadOnly': {
'canGc': ['FromRect'],
},
'DOMStringMap': {
'canGc': ['NamedSetter']
'canGc': ['NamedDeleter', 'NamedSetter']
},
"DOMTokenList": {