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

Side by Side Diff: tests/compiler/dart2js/begin_end_token_test.dart

Issue 10827394: Change line endings from Windows to Unix (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Rebased Created 8 years, 4 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
« no previous file with comments | « pkg/dartdoc/mirrors/dart2js_mirror.dart ('k') | tests/compiler/dart2js/mirrors_helper.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) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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('parser_helper.dart'); 5 #import('parser_helper.dart');
6 #import("../../../lib/compiler/implementation/scanner/scannerlib.dart"); 6 #import("../../../lib/compiler/implementation/scanner/scannerlib.dart");
7 #import("../../../lib/compiler/implementation/tree/tree.dart"); 7 #import("../../../lib/compiler/implementation/tree/tree.dart");
8 8
9 9
10 void testNode(Node node, String expected, String text, [bool hard = true]) { 10 void testNode(Node node, String expected, String text, [bool hard = true]) {
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 node = testExpression(text); 141 node = testExpression(text);
142 // Should parse as: (a.b)++. 142 // Should parse as: (a.b)++.
143 Expect.isNotNull(sendSet = node.asSendSet()); 143 Expect.isNotNull(sendSet = node.asSendSet());
144 testNode(sendSet.receiver, "a", text); 144 testNode(sendSet.receiver, "a", text);
145 testNode(sendSet.selector, "b", text); 145 testNode(sendSet.selector, "b", text);
146 testNode(sendSet.assignmentOperator, "++", text); 146 testNode(sendSet.assignmentOperator, "++", text);
147 Expect.isTrue(sendSet.arguments.isEmpty()); 147 Expect.isTrue(sendSet.arguments.isEmpty());
148 148
149 text = "++a[b]"; 149 text = "++a[b]";
150 // TODO(johnniwinther): SendSet generates the wrong end token in the following 150 // TODO(johnniwinther): SendSet generates the wrong end token in the following
151 // line. We should have [:testExpression(text):] instead of 151 // line. We should have [:testExpression(text):] instead of
152 // [:testExpression(text, "++a"):]. 152 // [:testExpression(text, "++a"):].
153 node = testExpression(text, "++a"); 153 node = testExpression(text, "++a");
154 Expect.isNotNull(sendSet = node.asSendSet()); 154 Expect.isNotNull(sendSet = node.asSendSet());
155 testNode(sendSet.receiver, "a", text); 155 testNode(sendSet.receiver, "a", text);
156 testNode(sendSet.selector, "[]", text, false); // Operator token is synthetic. 156 testNode(sendSet.selector, "[]", text, false); // Operator token is synthetic.
157 testNode(sendSet.assignmentOperator, "++", text); 157 testNode(sendSet.assignmentOperator, "++", text);
158 testNode(sendSet.arguments.head, "b", text); 158 testNode(sendSet.arguments.head, "b", text);
159 159
160 text = "a[b]++"; 160 text = "a[b]++";
161 node = testExpression(text); 161 node = testExpression(text);
162 Expect.isNotNull(sendSet = node.asSendSet()); 162 Expect.isNotNull(sendSet = node.asSendSet());
163 testNode(sendSet.receiver, "a", text); 163 testNode(sendSet.receiver, "a", text);
164 testNode(sendSet.selector, "[]", text, false); // Operator token is synthetic. 164 testNode(sendSet.selector, "[]", text, false); // Operator token is synthetic.
165 testNode(sendSet.assignmentOperator, "++", text); 165 testNode(sendSet.assignmentOperator, "++", text);
166 testNode(sendSet.arguments.head, "b", text); 166 testNode(sendSet.arguments.head, "b", text);
167 } 167 }
168 168
169 void main() { 169 void main() {
170 testUnaryExpression(); 170 testUnaryExpression();
171 testAssignment(); 171 testAssignment();
172 testIndex(); 172 testIndex();
173 testPostfix(); 173 testPostfix();
174 } 174 }
OLDNEW
« no previous file with comments | « pkg/dartdoc/mirrors/dart2js_mirror.dart ('k') | tests/compiler/dart2js/mirrors_helper.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698