Chromium Code Reviews| Index: Source/bindings/scripts/deprecated_idl_parser.pm |
| diff --git a/Source/bindings/scripts/deprecated_idl_parser.pm b/Source/bindings/scripts/deprecated_idl_parser.pm |
| index 9148d72b4377812fd2e86074816b1ac8ca90e0d2..b0f1688fa836973ab7eae8c5473f95a9007c2455 100644 |
| --- a/Source/bindings/scripts/deprecated_idl_parser.pm |
| +++ b/Source/bindings/scripts/deprecated_idl_parser.pm |
| @@ -334,27 +334,27 @@ sub typeRemoveNullableSuffix |
| my $nextAttribute_1 = '^(attribute|inherit|readonly)$'; |
| my $nextPrimitiveType_1 = '^(int|long|short|unsigned)$'; |
| my $nextPrimitiveType_2 = '^(double|float|unrestricted)$'; |
| -my $nextArgumentList_1 = '^(\(|::|ByteString|DOMString|Date|\[|any|boolean|byte|double|float|in|int|long|object|octet|optional|sequence|short|unrestricted|unsigned)$'; |
| +my $nextArgumentList_1 = '^(\(|::|ByteString|DOMString|Promise|PromiseResolver|Date|\[|any|boolean|byte|double|float|in|int|long|object|octet|optional|sequence|short|unrestricted|unsigned)$'; |
|
haraken
2013/09/02 21:44:21
Do you really need to make these changes to the ID
yusukesuzuki
2013/09/03 01:52:40
Promise and PromiseResolver won't be DOMObject sin
haraken
2013/09/03 02:12:19
Thanks for the clarification. Makes sense. Would y
yusukesuzuki
2013/09/03 09:35:55
Done.
|
| my $nextNonAnyType_1 = '^(boolean|byte|double|float|int|long|octet|short|unrestricted|unsigned)$'; |
| -my $nextInterfaceMember_1 = '^(\(|::|ByteString|DOMString|Date|any|attribute|boolean|byte|creator|deleter|double|float|getter|inherit|int|legacycaller|long|object|octet|readonly|sequence|serializer|setter|short|static|stringifier|unrestricted|unsigned|void)$'; |
| +my $nextInterfaceMember_1 = '^(\(|::|ByteString|DOMString|Promise|PromiseResolver|Date|any|attribute|boolean|byte|creator|deleter|double|float|getter|inherit|int|legacycaller|long|object|octet|readonly|sequence|serializer|setter|short|static|stringifier|unrestricted|unsigned|void)$'; |
| my $nextOptionalIteratorInterfaceOrObject_1 = '^(;|=)$'; |
| my $nextAttributeOrOperationOrIterator_1 = '^(static|stringifier)$'; |
| -my $nextAttributeOrOperationOrIterator_2 = '^(\(|::|ByteString|DOMString|Date|any|boolean|byte|creator|deleter|double|float|getter|int|legacycaller|long|object|octet|sequence|setter|short|unrestricted|unsigned|void)$'; |
| +my $nextAttributeOrOperationOrIterator_2 = '^(\(|::|ByteString|DOMString|Promise|PromiseResolver|Date|any|boolean|byte|creator|deleter|double|float|getter|int|legacycaller|long|object|octet|sequence|setter|short|unrestricted|unsigned|void)$'; |
| my $nextUnrestrictedFloatType_1 = '^(double|float)$'; |
| my $nextExtendedAttributeRest3_1 = '^(\,|::|\])$'; |
| -my $nextExceptionField_1 = '^(\(|::|ByteString|DOMString|Date|any|boolean|byte|double|float|int|long|object|octet|sequence|short|unrestricted|unsigned)$'; |
| -my $nextType_1 = '^(::|ByteString|DOMString|Date|any|boolean|byte|double|float|int|long|object|octet|sequence|short|unrestricted|unsigned)$'; |
| +my $nextExceptionField_1 = '^(\(|::|ByteString|DOMString|Promise|PromiseResolver|Date|any|boolean|byte|double|float|int|long|object|octet|sequence|short|unrestricted|unsigned)$'; |
| +my $nextType_1 = '^(::|ByteString|DOMString|Promise|PromiseResolver|Date|any|boolean|byte|double|float|int|long|object|octet|sequence|short|unrestricted|unsigned)$'; |
| my $nextSpecials_1 = '^(creator|deleter|getter|legacycaller|setter)$'; |
| my $nextDefinitions_1 = '^(::|callback|dictionary|enum|exception|interface|partial|typedef)$'; |
| -my $nextExceptionMembers_1 = '^(\(|::|ByteString|DOMString|Date|\[|any|boolean|byte|const|double|float|int|long|object|octet|optional|sequence|short|unrestricted|unsigned)$'; |
| +my $nextExceptionMembers_1 = '^(\(|::|ByteString|DOMString|Promise|PromiseResolver|Date|\[|any|boolean|byte|const|double|float|int|long|object|octet|optional|sequence|short|unrestricted|unsigned)$'; |
| my $nextAttributeRest_1 = '^(attribute|readonly)$'; |
| -my $nextInterfaceMembers_1 = '^(\(|::|ByteString|DOMString|Date|any|attribute|boolean|byte|const|creator|deleter|double|float|getter|inherit|int|legacycaller|long|object|octet|readonly|sequence|serializer|setter|short|static|stringifier|unrestricted|unsigned|void)$'; |
| -my $nextSingleType_1 = '^(::|ByteString|DOMString|Date|boolean|byte|double|float|int|long|object|octet|sequence|short|unrestricted|unsigned)$'; |
| +my $nextInterfaceMembers_1 = '^(\(|::|ByteString|DOMString|Promise|PromiseResolver|Date|any|attribute|boolean|byte|const|creator|deleter|double|float|getter|inherit|int|legacycaller|long|object|octet|readonly|sequence|serializer|setter|short|static|stringifier|unrestricted|unsigned|void)$'; |
| +my $nextSingleType_1 = '^(::|ByteString|DOMString|Promise|PromiseResolver|Date|boolean|byte|double|float|int|long|object|octet|sequence|short|unrestricted|unsigned)$'; |
| my $nextArgumentName_1 = '^(attribute|callback|const|creator|deleter|dictionary|enum|exception|getter|implements|inherit|interface|legacycaller|partial|serializer|setter|static|stringifier|typedef|unrestricted)$'; |
| my $nextConstValue_1 = '^(false|true)$'; |
| my $nextConstValue_2 = '^(-|Infinity|NaN)$'; |
| my $nextDefinition_1 = '^(callback|interface)$'; |
| -my $nextAttributeOrOperationRest_1 = '^(\(|::|ByteString|DOMString|Date|any|boolean|byte|double|float|int|long|object|octet|sequence|short|unrestricted|unsigned|void)$'; |
| +my $nextAttributeOrOperationRest_1 = '^(\(|::|ByteString|DOMString|Promise|PromiseResolver|Date|any|boolean|byte|double|float|int|long|object|octet|sequence|short|unrestricted|unsigned|void)$'; |
| my $nextUnsignedIntegerType_1 = '^(int|long|short)$'; |
| my $nextDefaultValue_1 = '^(-|Infinity|NaN|false|null|true)$'; |
| @@ -1862,6 +1862,14 @@ sub parseNonAnyType |
| $self->assertTokenValue($self->getToken(), "DOMString", __LINE__); |
| return "DOMString" . $self->parseTypeSuffix(); |
| } |
| + if ($next->value() eq "Promise") { |
| + $self->assertTokenValue($self->getToken(), "Promise", __LINE__); |
| + return "Promise" . $self->parseTypeSuffix(); |
| + } |
| + if ($next->value() eq "PromiseResolver") { |
| + $self->assertTokenValue($self->getToken(), "PromiseResolver", __LINE__); |
| + return "PromiseResolver" . $self->parseTypeSuffix(); |
| + } |
| if ($next->value() eq "sequence") { |
| $self->assertTokenValue($self->getToken(), "sequence", __LINE__); |
| $self->assertTokenValue($self->getToken(), "<", __LINE__); |