LibIDL: Allow extended attributes on non-required IDL dictionary members

For example, WebAssembly.Memory will have:

    [EnforceRange] unsigned long maximum;
This commit is contained in:
Timothy Flynn 2023-03-15 18:33:09 -04:00 committed by Andreas Kling
commit 1ff75618c0
Notes: sideshowbarker 2024-07-16 22:50:31 +09:00

View file

@ -727,10 +727,11 @@ void Parser::parse_dictionary(Interface& interface)
if (lexer.consume_specific("required")) {
required = true;
consume_whitespace();
if (lexer.consume_specific('['))
extended_attributes = parse_extended_attributes();
}
if (lexer.consume_specific('['))
extended_attributes = parse_extended_attributes();
auto type = parse_type();
consume_whitespace();