Remove dynamic invocations from custom elements in html_dart2js.

Registering custom elements are already broken -- see: https://github.com/dart-lang/sdk/issues/49536. There are plans on deleting this code at some point. This current change cleans up dynamic invocations in the deprecated code.

Removes cruft on already-deprecated code and doing it now because I assume dynamic clean up will finish before the issue resolves.

Change-Id: Ic6250c139c5d9b08d88650110f55442a7bf5dd42
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/259247
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Lasse Nielsen <lrn@google.com>
Commit-Queue: Kallen Tu <kallentu@google.com>
Reviewed-by: Leaf Petersen <leafp@google.com>
This commit is contained in:
Kallen Tu 2022-09-20 16:16:06 +00:00 committed by Commit Bot
parent 139344eb28
commit 7578614639
3 changed files with 9 additions and 10 deletions

View file

@ -30,10 +30,7 @@
"Dynamic invocation of 'call'.": 2,
"Dynamic access of 'attributes'.": 1,
"Dynamic invocation of '[]'.": 1,
"Dynamic invocation of 'toLowerCase'.": 1,
"Dynamic invocation of 'attached'.": 1,
"Dynamic invocation of 'detached'.": 1,
"Dynamic invocation of 'attributeChanged'.": 1
"Dynamic invocation of 'toLowerCase'.": 1
},
"org-dartlang-sdk:///lib/html/html_common/conversions.dart": {
"Dynamic invocation of '[]='.": 1

View file

@ -40150,15 +40150,16 @@ _callConstructor(constructor, interceptor) {
};
}
_callAttached(receiver) {
_callAttached(Element receiver) {
return receiver.attached();
}
_callDetached(receiver) {
_callDetached(Element receiver) {
return receiver.detached();
}
_callAttributeChanged(receiver, name, oldValue, newValue) {
_callAttributeChanged(
Element receiver, String name, String oldValue, String newValue) {
return receiver.attributeChanged(name, oldValue, newValue);
}

View file

@ -16,15 +16,16 @@ _callConstructor(constructor, interceptor) {
};
}
_callAttached(receiver) {
_callAttached(Element receiver) {
return receiver.attached();
}
_callDetached(receiver) {
_callDetached(Element receiver) {
return receiver.detached();
}
_callAttributeChanged(receiver, name, oldValue, newValue) {
_callAttributeChanged(
Element receiver, String name, String oldValue, String newValue) {
return receiver.attributeChanged(name, oldValue, newValue);
}