[web-nfc] Invalid Web IDL loop between NDEFRecordInit and NDEFMessageInit (#620)

rakuco has just created a new issue for https://github.com/w3c/web-nfc:

== Invalid Web IDL loop between NDEFRecordInit and NDEFMessageInit ==
https://heycam.github.io/webidl/#idl-dictionaries says:

> The type of a dictionary member must not include the dictionary it appears on. A type includes a dictionary D if at least one of the following is true:
> 1. the type is D
> 1. the type is a dictionary that inherits from D
> 1. the type is a nullable type whose inner type includes D
> 1. the type is a sequence type or frozen array whose element type includes D
> 1. the type is a union type, one of whose member types includes D
> 1. the type is a dictionary, one of whose members or inherited members has a type that includes D
> 1. the type is record<K, V> where V includes D

#454 introduced a case of 4, 5 and 6, as right now `NDEFRecordInit.data` can be an `NDEFMessageInit`, which is a dictionary with a sequence of `NDEFRecordInit`s. This creates a loop that is not allowed by Web IDL and which can cause implementation issues like https://bugs.chromium.org/p/chromium/issues/detail?id=1242274

Please view or discuss this issue at https://github.com/w3c/web-nfc/issues/620 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Tuesday, 31 August 2021 08:43:45 UTC