Skip to content

Conversation

@domenic
Copy link
Member

@domenic domenic commented Oct 13, 2019

Fixes so far:

  • Removed [NoInterfaceObject] support and made a single [Exposed] mandatory to align with ongoing/upcoming Web IDL spec changes. Fixed how [Exposed] arguments are processed as that changed in webidl2.
  • Stopped checking for .arguments when checking [Global] validity; I'm not sure what that check was for and it doesn't seem to work anymore anyway.
  • Updated to check the .special property instead of the .getter, .setter, .deleter, .stringifier, .static properties
  • Changed to check for falsy name properties for indexed/named getters/setters, instead of null. webidl2 is now sometimes returning undefined and sometimes returning the empty string (I think via the prototype chain? There is no name own property.)

Tests still failing:

  • Escaped (underscore-prefixed) name handling got changed in webidl2, causing various failures due to _analyzeMembers (lib/constructs/interface.js:367:15) which seems to prohibit any underscores from appearing. I'm unsure what the intent of the original code was, or the intent of the webidl2 changes, which seem likely to be those in fix: escape non-member top identifiers w3c/webidl2.js#229. This is causing lots of early failures which might mask other issues.
  • sequence<sequence<USVString>> in URLSearchParams.webidl is being treated as something like sequence<USVString>. I fixed several similar failures, which were caused by webidl2 switching idlType from the inner type to an array containing the inner type. I'm unsure why this one remains.

Help very much appreciated from anyone who is able to figure these remaining things out.

/cc @saschanaz

@saschanaz
Copy link
Contributor

* Escaped (underscore-prefixed) name handling got changed in webidl2, causing various failures due to `_analyzeMembers (lib/constructs/interface.js:367:15)`

I think that code is not useful anymore as w3c/webidl2.js#403 made it throw early.

@domenic
Copy link
Member Author

domenic commented Oct 14, 2019

Awesome, thanks! With that hint I got a decent bit more working. What's left is still underscore-related; it seems like previously underscores were stripped and now they are retained? So jsdom is putting underscores in the output for _const and _null.

@saschanaz
Copy link
Contributor

That looks like a bug, I will investigate.

@domenic
Copy link
Member Author

domenic commented Oct 14, 2019

@saschanaz still one failure, where

[Exposed=Window]
interface _UnderscoredProperties {
  const byte _const = 42;
  attribute byte _attribute;
  static void _static(DOMString _void);
  void _operation(sequence<DOMString> _sequence);
};

seems to generate _const, instead of const, for the name of the constant member.

@domenic domenic merged commit 43c480e into master Oct 19, 2019
@domenic domenic deleted the update-webidl2 branch October 19, 2019 17:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants