Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(14)

Side by Side Diff: tests/language/type_parameter_test.dart

Issue 19030004: Stop resolving classes prematurely in the vm (issue 11023). (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« runtime/vm/object.cc ('K') | « tests/language/language_dart2js.status ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 import "package:expect/expect.dart"; 5 import "package:expect/expect.dart";
6 6
7 class A<T> { 7 class A<T> {
8 Function closure; 8 Function closure;
9 A._(this.closure); 9 A._(this.closure);
10 10
(...skipping 11 matching lines...) Expand all
22 T /// 02: static type warning, dynamic type error 22 T /// 02: static type warning, dynamic type error
23 a) { 23 a) {
24 final 24 final
25 T /// 03: static type warning, dynamic type error 25 T /// 03: static type warning, dynamic type error
26 a = "not_null"; 26 a = "not_null";
27 print(a); 27 print(a);
28 return a; 28 return a;
29 } 29 }
30 30
31 static final 31 static final
32 T /// 04: static type warning, dynamic type error 32 T /// 04: static type warning, compile-time error
33 staticField = "not_null"; 33 staticField = "not_null";
34 34
35 // Assigning null to a malformed type is not a dynamic error. 35 // Assigning null to a malformed type is not a dynamic error.
36 static 36 static
37 T staticMethod2(T a) { 37 T staticMethod2(T a) {
38 final T a = null; 38 final T a = null;
39 print(a); 39 print(a);
40 return a; 40 return a;
41 } 41 }
42 42
(...skipping 14 matching lines...) Expand all
57 s = ((new A<int>.bar()).closure)(); 57 s = ((new A<int>.bar()).closure)();
58 Expect.isTrue(s is Set<int>); 58 Expect.isTrue(s is Set<int>);
59 Expect.isFalse(s is Set<double>); 59 Expect.isFalse(s is Set<double>);
60 60
61 A.staticMethod("not_null"); 61 A.staticMethod("not_null");
62 print(A.staticField); 62 print(A.staticField);
63 63
64 A.staticMethod2(null); 64 A.staticMethod2(null);
65 print(A.staticField2); 65 print(A.staticField2);
66 } 66 }
OLDNEW
« runtime/vm/object.cc ('K') | « tests/language/language_dart2js.status ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698