More compact lowering of late variable error messages by front-end #43995
Labels
customer-dart2js
customer-dev-compiler
front-end-kernel
legacy-area-front-end
Legacy: Use area-dart-model instead.
The front-end lowering of late variables is too large for dart2js (see #43361) and DDC.
One of the reasons is that the lowering contains comprehensive error messages.
These could be factored so that the call to the error contains only the name, and the rest of the message is provided by the constructor.
Instead of:
generate:
There should also be a target configuration option to omit the names as the name can be guessed from the stack-trace.
For the best code from dart2js, the
LateInitializationErrorImpl
constructor without the name should be a separate named constructor (not an optional name argument, as the default occurs at the call site)./cc @johnniwinther
The text was updated successfully, but these errors were encountered: