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

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

Issue 1182913003: Split TypedSelector into Selector and TypeMask. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Add SelectorMask for FunctionSetNode.cache Created 5 years, 6 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
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 library compiler_helper; 5 library compiler_helper;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 import "package:expect/expect.dart"; 8 import "package:expect/expect.dart";
9 9
10 import 'package:compiler/compiler.dart' as api; 10 import 'package:compiler/compiler.dart' as api;
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 analyzeAll: analyzeAll, 102 analyzeAll: analyzeAll,
103 analyzeOnly: analyzeOnly, 103 analyzeOnly: analyzeOnly,
104 coreSource: coreSource, 104 coreSource: coreSource,
105 disableInlining: disableInlining, 105 disableInlining: disableInlining,
106 enableMinification: minify, 106 enableMinification: minify,
107 trustTypeAnnotations: trustTypeAnnotations, 107 trustTypeAnnotations: trustTypeAnnotations,
108 expectedErrors: expectedErrors, 108 expectedErrors: expectedErrors,
109 expectedWarnings: expectedWarnings, 109 expectedWarnings: expectedWarnings,
110 outputProvider: outputProvider); 110 outputProvider: outputProvider);
111 compiler.registerSource(uri, code); 111 compiler.registerSource(uri, code);
112 compiler.diagnosticHandler = createHandler(compiler, code);
112 return compiler; 113 return compiler;
113 } 114 }
114 115
115 Future<String> compileAll(String code, 116 Future<String> compileAll(String code,
116 {Map<String, String> coreSource, 117 {Map<String, String> coreSource,
117 bool disableInlining: true, 118 bool disableInlining: true,
118 bool trustTypeAnnotations: false, 119 bool trustTypeAnnotations: false,
119 bool minify: false, 120 bool minify: false,
120 int expectedErrors, 121 int expectedErrors,
121 int expectedWarnings}) { 122 int expectedWarnings}) {
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
259 regexp = regexp.replaceAll(xRe, '(?:$anyIdentifier)'); 260 regexp = regexp.replaceAll(xRe, '(?:$anyIdentifier)');
260 final spaceRe = new RegExp('\\s+'); 261 final spaceRe = new RegExp('\\s+');
261 regexp = regexp.replaceAll(spaceRe, '(?:\\s*)'); 262 regexp = regexp.replaceAll(spaceRe, '(?:\\s*)');
262 if (shouldMatch) { 263 if (shouldMatch) {
263 Expect.isTrue(new RegExp(regexp).hasMatch(generated)); 264 Expect.isTrue(new RegExp(regexp).hasMatch(generated));
264 } else { 265 } else {
265 Expect.isFalse(new RegExp(regexp).hasMatch(generated)); 266 Expect.isFalse(new RegExp(regexp).hasMatch(generated));
266 } 267 }
267 }); 268 });
268 } 269 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698