| OLD | NEW |
| 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 library members_test; | 5 library members_test; |
| 6 | 6 |
| 7 import 'package:expect/expect.dart'; | 7 import 'package:expect/expect.dart'; |
| 8 import "package:async_helper/async_helper.dart"; | 8 import "package:async_helper/async_helper.dart"; |
| 9 import 'type_test_helper.dart'; | 9 import 'type_test_helper.dart'; |
| 10 import 'package:compiler/src/elements/resolution_types.dart'; | 10 import 'package:compiler/src/elements/resolution_types.dart'; |
| (...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 180 } | 180 } |
| 181 class B<T> { | 181 class B<T> { |
| 182 T field; | 182 T field; |
| 183 void method(T t) {} | 183 void method(T t) {} |
| 184 static staticMethod() {} | 184 static staticMethod() {} |
| 185 toString([T t]) {} | 185 toString([T t]) {} |
| 186 } | 186 } |
| 187 class C<S> extends B<S> {} | 187 class C<S> extends B<S> {} |
| 188 class D extends C<int> {} | 188 class D extends C<int> {} |
| 189 class E extends D {} | 189 class E extends D {} |
| 190 """, useMockCompiler: false).then((env) { | 190 """, compileMode: CompileMode.memory).then((env) { |
| 191 ResolutionInterfaceType bool_ = env['bool']; | 191 ResolutionInterfaceType bool_ = env['bool']; |
| 192 ResolutionInterfaceType String_ = env['String']; | 192 ResolutionInterfaceType String_ = env['String']; |
| 193 ResolutionInterfaceType int_ = env['int']; | 193 ResolutionInterfaceType int_ = env['int']; |
| 194 ResolutionDynamicType dynamic_ = env['dynamic']; | 194 ResolutionDynamicType dynamic_ = env['dynamic']; |
| 195 ResolutionVoidType void_ = env['void']; | 195 ResolutionVoidType void_ = env['void']; |
| 196 ResolutionInterfaceType Type_ = env['Type']; | 196 ResolutionInterfaceType Type_ = env['Type']; |
| 197 ResolutionInterfaceType Invocation_ = env['Invocation']; | 197 ResolutionInterfaceType Invocation_ = env['Invocation']; |
| 198 | 198 |
| 199 ResolutionInterfaceType Object_ = env['Object']; | 199 ResolutionInterfaceType Object_ = env['Object']; |
| 200 checkMemberCount(Object_, 5 /*declared*/, interfaceMembers: true); | 200 checkMemberCount(Object_, 5 /*declared*/, interfaceMembers: true); |
| (...skipping 541 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 742 | 742 |
| 743 // Ensure that members have been computed on all classes. | 743 // Ensure that members have been computed on all classes. |
| 744 MembersCreator.computeAllClassMembers(env.resolution, C.element); | 744 MembersCreator.computeAllClassMembers(env.resolution, C.element); |
| 745 | 745 |
| 746 checkMember(C, 'm', | 746 checkMember(C, 'm', |
| 747 checkType: NO_CLASS_MEMBER, | 747 checkType: NO_CLASS_MEMBER, |
| 748 inheritedFrom: A, | 748 inheritedFrom: A, |
| 749 functionType: env.functionType(dynamic_, [])); | 749 functionType: env.functionType(dynamic_, [])); |
| 750 })); | 750 })); |
| 751 } | 751 } |
| OLD | NEW |