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

Side by Side Diff: pkg/analyzer2dart/test/sexpr_data.dart

Issue 1161793002: Revert "dart2js cps: 'is' checks on types with type arguments." (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 7 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
« no previous file with comments | « no previous file | pkg/compiler/lib/src/cps_ir/cps_ir_builder.dart » ('j') | 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) 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 /// Test data for sexpr_test. 5 /// Test data for sexpr_test.
6 library test.sexpr.data; 6 library test.sexpr.data;
7 7
8 import 'test_helper.dart'; 8 import 'test_helper.dart';
9 9
10 class TestSpec extends TestSpecBase { 10 class TestSpec extends TestSpecBase {
(...skipping 1048 matching lines...) Expand 10 before | Expand all | Expand 10 after
1059 1059
1060 const Group('Type operators', const <TestSpec>[ 1060 const Group('Type operators', const <TestSpec>[
1061 const TestSpec(''' 1061 const TestSpec('''
1062 main(a) { 1062 main(a) {
1063 return a is String; 1063 return a is String;
1064 } 1064 }
1065 ''', ''' 1065 ''', '''
1066 (FunctionDefinition main () (a) return 1066 (FunctionDefinition main () (a) return
1067 (LetCont ((k0 (v0) 1067 (LetCont ((k0 (v0)
1068 (InvokeContinuation return (v0)))) 1068 (InvokeContinuation return (v0))))
1069 (TypeOperator is a String () k0))) 1069 (TypeOperator is a String k0)))
1070 '''), 1070 '''),
1071 1071
1072 const TestSpec(''' 1072 const TestSpec('''
1073 main(a) { 1073 main(a) {
1074 return a is List<String>; 1074 return a is List<String>;
1075 } 1075 }
1076 ''', ''' 1076 ''', '''
1077 (FunctionDefinition main () (a) return 1077 (FunctionDefinition main () (a) return
1078 (LetCont ((k0 (v0) 1078 (LetCont ((k0 (v0)
1079 (InvokeContinuation return (v0)))) 1079 (InvokeContinuation return (v0))))
1080 (TypeOperator is a List<String> () k0))) 1080 (TypeOperator is a List<String> k0)))
1081 '''), 1081 '''),
1082 1082
1083 const TestSpec(''' 1083 const TestSpec('''
1084 main(a) { 1084 main(a) {
1085 return a is Comparator<String>; 1085 return a is Comparator<String>;
1086 } 1086 }
1087 ''', ''' 1087 ''', '''
1088 (FunctionDefinition main () (a) return 1088 (FunctionDefinition main () (a) return
1089 (LetCont ((k0 (v0) 1089 (LetCont ((k0 (v0)
1090 (InvokeContinuation return (v0)))) 1090 (InvokeContinuation return (v0))))
1091 (TypeOperator is a Comparator<String> () k0))) 1091 (TypeOperator is a Comparator<String> k0)))
1092 '''), 1092 '''),
1093 1093
1094 const TestSpec(''' 1094 const TestSpec('''
1095 main(a) { 1095 main(a) {
1096 return a is! String; 1096 return a is! String;
1097 } 1097 }
1098 ''', ''' 1098 ''', '''
1099 (FunctionDefinition main () (a) return 1099 (FunctionDefinition main () (a) return
1100 (LetCont ((k0 (v0) 1100 (LetCont ((k0 (v0)
1101 (LetCont ((k1 (v1) 1101 (LetCont ((k1 (v1)
1102 (InvokeContinuation return (v1)))) 1102 (InvokeContinuation return (v1))))
1103 (LetCont ((k2 () 1103 (LetCont ((k2 ()
1104 (LetPrim (v2 (Constant (Bool false))) 1104 (LetPrim (v2 (Constant (Bool false)))
1105 (InvokeContinuation k1 (v2)))) 1105 (InvokeContinuation k1 (v2))))
1106 (k3 () 1106 (k3 ()
1107 (LetPrim (v3 (Constant (Bool true))) 1107 (LetPrim (v3 (Constant (Bool true)))
1108 (InvokeContinuation k1 (v3))))) 1108 (InvokeContinuation k1 (v3)))))
1109 (Branch (IsTrue v0) k2 k3))))) 1109 (Branch (IsTrue v0) k2 k3)))))
1110 (TypeOperator is a String () k0))) 1110 (TypeOperator is a String k0)))
1111 '''), 1111 '''),
1112 1112
1113 const TestSpec(''' 1113 const TestSpec('''
1114 main(a) { 1114 main(a) {
1115 return a as String; 1115 return a as String;
1116 } 1116 }
1117 ''', ''' 1117 ''', '''
1118 (FunctionDefinition main () (a) return 1118 (FunctionDefinition main () (a) return
1119 (LetCont ((k0 (v0) 1119 (LetCont ((k0 (v0)
1120 (InvokeContinuation return (v0)))) 1120 (InvokeContinuation return (v0))))
1121 (TypeOperator as a String () k0))) 1121 (TypeOperator as a String k0)))
1122 '''), 1122 '''),
1123 ]), 1123 ]),
1124 1124
1125 const Group('For in loop', const <TestSpec>[ 1125 const Group('For in loop', const <TestSpec>[
1126 // TODO(johnniwinther): Add tests for `i` as top-level, static and instance 1126 // TODO(johnniwinther): Add tests for `i` as top-level, static and instance
1127 // fields. 1127 // fields.
1128 const TestSpec(''' 1128 const TestSpec('''
1129 main(a) { 1129 main(a) {
1130 for (var i in a) { 1130 for (var i in a) {
1131 print(i); 1131 print(i);
(...skipping 408 matching lines...) Expand 10 before | Expand all | Expand 10 after
1540 (LetCont ((k0 () 1540 (LetCont ((k0 ()
1541 (LetPrim (v0 (Constant (Null))) 1541 (LetPrim (v0 (Constant (Null)))
1542 (InvokeContinuation return (v0))))) 1542 (InvokeContinuation return (v0)))))
1543 (LetHandler ((v1 v2) 1543 (LetHandler ((v1 v2)
1544 (InvokeContinuation k0 ())) 1544 (InvokeContinuation k0 ()))
1545 (LetPrim (v3 (Constant (Null))) 1545 (LetPrim (v3 (Constant (Null)))
1546 (InvokeContinuation return (v3)))))) 1546 (InvokeContinuation return (v3))))))
1547 '''), 1547 '''),
1548 ]), 1548 ]),
1549 ]; 1549 ];
OLDNEW
« no previous file with comments | « no previous file | pkg/compiler/lib/src/cps_ir/cps_ir_builder.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698