Tree-shaking unused superclass method named "error" fails #30962
Labels
area-web-js
Issues related to JavaScript support for Dart Web, including DDC, dart2js, and JS interop.
type-bug
Incorrect behavior (everything from a crash to more subtle misbehavior)
web-dart2js
In the following code:
Super.error()
is unreachable, but dart2js (as of 0c005a3) fails to tree-shake it:This seems to be dependent on the name of the method. If I change it to
error_()
:Super.error_()
does seem to be tree-shaken:This came up in practice when trying to reduce the code size of the
http
package and its dependencies.The text was updated successfully, but these errors were encountered: