| Index: pkg/compiler/lib/src/resolution/members.dart
|
| diff --git a/pkg/compiler/lib/src/resolution/members.dart b/pkg/compiler/lib/src/resolution/members.dart
|
| index a69b35950f82b7543c57db1a381905fd582867f6..a382b7510bc540a71a507c5b220adec4bd9988cb 100644
|
| --- a/pkg/compiler/lib/src/resolution/members.dart
|
| +++ b/pkg/compiler/lib/src/resolution/members.dart
|
| @@ -1121,6 +1121,14 @@ class ResolverVisitor extends MappingVisitor<ResolutionResult> {
|
| type = resolveTypeAnnotation(typeNode);
|
| sendStructure = new IsStructure(type);
|
| }
|
| +
|
| + // GENERIC_METHODS: Method type variables are not reified so we must warn
|
| + // about the error which will occur at runtime.
|
| + if (type is MethodTypeVariableType) {
|
| + reporter.reportWarningMessage(
|
| + node, MessageKind.TYPE_VARIABLE_FROM_METHOD_NOT_REIFIED);
|
| + }
|
| +
|
| registry.registerTypeUse(new TypeUse.isCheck(type));
|
| registry.registerSendStructure(node, sendStructure);
|
| return const NoneResult();
|
| @@ -1133,6 +1141,14 @@ class ResolverVisitor extends MappingVisitor<ResolutionResult> {
|
|
|
| Node typeNode = node.arguments.head;
|
| DartType type = resolveTypeAnnotation(typeNode);
|
| +
|
| + // GENERIC_METHODS: Method type variables are not reified so we must warn
|
| + // about the error which will occur at runtime.
|
| + if (type is MethodTypeVariableType) {
|
| + reporter.reportWarningMessage(
|
| + node, MessageKind.TYPE_VARIABLE_FROM_METHOD_NOT_REIFIED);
|
| + }
|
| +
|
| registry.registerTypeUse(new TypeUse.asCast(type));
|
| registry.registerSendStructure(node, new AsStructure(type));
|
| return const NoneResult();
|
| @@ -1888,6 +1904,12 @@ class ResolverVisitor extends MappingVisitor<ResolutionResult> {
|
| // TODO(johnniwinther): Clean up registration of elements and selectors
|
| // for this case.
|
| } else {
|
| + // GENERIC_METHODS: Method type variables are not reified so we must warn
|
| + // about the error which will occur at runtime.
|
| + if (element.type is MethodTypeVariableType) {
|
| + reporter.reportWarningMessage(
|
| + node, MessageKind.TYPE_VARIABLE_FROM_METHOD_NOT_REIFIED);
|
| + }
|
| semantics = new StaticAccess.typeParameterTypeLiteral(element);
|
| }
|
|
|
|
|