DescriptionAdjusts dart2js SSA builder to tolerate method type arguments.
This CL changes `Types.getClassContext` to return null for method type
arguments (indicating that the given `type` does not contain any type
variables, which fits the current "ignore them" approach to that kind
of type variable). It introduces a new class `MethodTypeVariableType`
which models a method type variables and ensures that it is treated
as `dynamic` (such that type annotations are permissive, and usages
as a type expression `T` in `.. is T` or `.. as T` are treated like
a malformed type). For RTI, method type variables are ignored (such
that no additional classes are claimed to be needed for RTI due to
method type variables, no matter how they are used). Finally,
`SsaBuilder.addTypeVariableReference` generates code yielding the
value `dynamic` for method type variables.
Adresses issue 26436.
R=johnniwinther@google.com
Committed: https://github.com/dart-lang/sdk/commit/ee926fac8dd4fbc1b1cec9c8e836be916baf81b1
Patch Set 1 #
Total comments: 1
Messages
Total messages: 5 (2 generated)
|