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

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

Issue 693153002: Support is/as expressions in analyzer2dart. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 1 month 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
« no previous file with comments | « pkg/analyzer2dart/test/end2end_data.dart ('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) 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 const List<Group> TEST_DATA = const [ 10 const List<Group> TEST_DATA = const [
(...skipping 1027 matching lines...) Expand 10 before | Expand all | Expand 10 after
1038 (LetPrim v6 (Constant IntConstant(1))) 1038 (LetPrim v6 (Constant IntConstant(1)))
1039 (LetCont (k5 v7) 1039 (LetCont (k5 v7)
1040 (InvokeContinuation* k0 v7)) 1040 (InvokeContinuation* k0 v7))
1041 (InvokeMethod v1 + v6 k5)) 1041 (InvokeMethod v1 + v6 k5))
1042 (InvokeStatic print v1 k4)) 1042 (InvokeStatic print v1 k4))
1043 (Branch (IsTrue v3) k3 k2)) 1043 (Branch (IsTrue v3) k3 k2))
1044 (InvokeMethod v1 < v2 k1)) 1044 (InvokeMethod v1 < v2 k1))
1045 (InvokeContinuation k0 v0)) 1045 (InvokeContinuation k0 v0))
1046 '''), 1046 '''),
1047 ]), 1047 ]),
1048
1049 const Group('Type operators', const <TestSpec>[
1050 const TestSpec('''
1051 main(a) {
1052 return a is String;
1053 }
1054 ''', '''
1055 (FunctionDefinition main (a return)
1056 (LetCont (k0 v0)
1057 (InvokeContinuation return v0))
1058 (TypeOperator is a String k0))
1059 '''),
1060
1061 const TestSpec('''
1062 main(a) {
1063 return a is List<String>;
1064 }
1065 ''', '''
1066 (FunctionDefinition main (a return)
1067 (LetCont (k0 v0)
1068 (InvokeContinuation return v0))
1069 (TypeOperator is a List<String> k0))
1070 '''),
1071
1072 const TestSpec('''
1073 main(a) {
1074 return a is Comparator<String>;
1075 }
1076 ''', '''
1077 (FunctionDefinition main (a return)
1078 (LetCont (k0 v0)
1079 (InvokeContinuation return v0))
1080 (TypeOperator is a Comparator<String> k0))
1081 '''),
1082
1083 const TestSpec('''
1084 main(a) {
1085 return a is! String;
1086 }
1087 ''', '''
1088 (FunctionDefinition main (a return)
1089 (LetCont (k0 v0)
1090 (LetCont (k1 v1)
1091 (InvokeContinuation return v1))
1092 (LetCont (k2)
1093 (LetPrim v2 (Constant BoolConstant(false)))
1094 (InvokeContinuation k1 v2))
1095 (LetCont (k3)
1096 (LetPrim v3 (Constant BoolConstant(true)))
1097 (InvokeContinuation k1 v3))
1098 (Branch (IsTrue v0) k2 k3))
1099 (TypeOperator is a String k0))
1100 '''),
1101
1102 const TestSpec('''
1103 main(a) {
1104 return a as String;
1105 }
1106 ''', '''
1107 (FunctionDefinition main (a return)
1108 (LetCont (k0 v0)
1109 (InvokeContinuation return v0))
1110 (TypeOperator as a String k0))
1111 '''),
1112 ]),
1048 ]; 1113 ];
OLDNEW
« no previous file with comments | « pkg/analyzer2dart/test/end2end_data.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698