Skip to content

Conversation

@darrnshn
Copy link
Collaborator

Fixes #612 . Changes behaviour: you can no longer pass in an option with null is2D.

Hi @tabatkins , PTAL

@darrnshn darrnshn requested a review from tabatkins January 30, 2018 22:46
@tabatkins
Copy link
Member

Why'd you make it required? That kinda clashes with providing a default value for it. ^_^

@darrnshn
Copy link
Collaborator Author

Oh oops, I thought required would make is2D not nullable. Fixed.

@tabatkins
Copy link
Member

It was never nullable (that would have required a boolean?), it just could have been not passed before; adding a default value prevents that.

@tabatkins tabatkins merged commit 60d2b16 into w3c:master Jan 30, 2018
@darrnshn
Copy link
Collaborator Author

@tabatkins Hi Tab, it appears that this changes behaviour in a way that I didn't expect.

Before, we had two possibilities:

  1. Don't pass in options. is2D is inferred from matrix.is2D.
  2. Pass in options. is2D is set to options.is2D.

It seems that with this change, the first possibility changes to:

  1. Don't pass in options. is2D is false (the default value).

I didn't expect this because I thought options was an optional argument, we would still have the "infer" code path, but it looks like IDL magic has made it impossible.

Is this the intended behaviour? Or is this a bug with the Blink IDL?

@tabatkins
Copy link
Member

Ah, you're right, that is a behavior change. We should revert this and just address the issue more directly, then.

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.

2 participants