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

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

Issue 177293002: Version 1.2.0-dev.5.15 (Closed) Base URL: http://dart.googlecode.com/svn/trunk/dart/
Patch Set: Created 6 years, 10 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 | « tests/compiler/dart2js/dart2js.status ('k') | tests/language/logical_expression_test.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 that logical or-expressions don't introduce unnecessary nots. 5 // Test that logical or-expressions don't introduce unnecessary nots.
6 6
7 import "package:async_helper/async_helper.dart"; 7 import "package:async_helper/async_helper.dart";
8 import 'compiler_helper.dart'; 8 import 'compiler_helper.dart';
9 9
10 const String TEST_ONE = r""" 10 const String TEST_ONE = r"""
(...skipping 27 matching lines...) Expand all
38 // var t1 = list == null; 38 // var t1 = list == null;
39 // if (t1) bar.call$0(); 39 // if (t1) bar.call$0();
40 // if (t1 || bar.call$0() === true) bar.call$0(); 40 // if (t1 || bar.call$0() === true) bar.call$0();
41 // if (t1 || bar.call$0() === true) bar.call$0(); 41 // if (t1 || bar.call$0() === true) bar.call$0();
42 compileAndMatchFuzzy(TEST_TWO, 'foo', 42 compileAndMatchFuzzy(TEST_TWO, 'foo',
43 r"""var x = x == null; 43 r"""var x = x == null;
44 if \(x\) [^;]+; 44 if \(x\) [^;]+;
45 if \(x \|\| [a-zA-Z0-9$.]+\(\) === true\) [^;]+; 45 if \(x \|\| [a-zA-Z0-9$.]+\(\) === true\) [^;]+;
46 if \(x \|\| [a-zA-Z0-9$.]+\(\) === true\) [^;]+;"""); 46 if \(x \|\| [a-zA-Z0-9$.]+\(\) === true\) [^;]+;""");
47 } 47 }
OLDNEW
« no previous file with comments | « tests/compiler/dart2js/dart2js.status ('k') | tests/language/logical_expression_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698