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

Unified Diff: pkg/front_end/lib/src/fasta/testing/kernel_chain.dart

Issue 2982093003: Unifying compiler context (Closed)
Patch Set: Created 3 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: pkg/front_end/lib/src/fasta/testing/kernel_chain.dart
diff --git a/pkg/front_end/lib/src/fasta/testing/kernel_chain.dart b/pkg/front_end/lib/src/fasta/testing/kernel_chain.dart
index 7eff138851329b0bc3b76503d9344378a4f06402..bb54663667c83a16baac929c060c833df4274db7 100644
--- a/pkg/front_end/lib/src/fasta/testing/kernel_chain.dart
+++ b/pkg/front_end/lib/src/fasta/testing/kernel_chain.dart
@@ -25,7 +25,7 @@ import 'package:kernel/ast.dart' show Library, Program;
import '../kernel/verifier.dart' show verifyProgram;
-import '../compiler_command_line.dart';
+import '../compiler_context.dart';
import 'package:kernel/binary/ast_to_binary.dart' show BinaryPrinter;
@@ -67,7 +67,7 @@ class Verify extends Step<Program, Program, ChainContext> {
String get name => "verify";
Future<Result<Program>> run(Program program, ChainContext context) async {
- return await CompilerCommandLine.withGlobalOptions("", [""], (_) async {
+ return await CompilerContext.runWithDefaultOptions((_) async {
var errors = verifyProgram(program, isOutline: !fullCompile);
if (errors.isEmpty) {
return pass(program);
@@ -191,7 +191,7 @@ class Compile extends Step<TestDescription, Program, CompileContext> {
Future<Result<Program>> run(
TestDescription description, CompileContext context) async {
Result<Program> result;
- reportError(CompilationError error) {
+ reportError(CompilationMessage error) {
result ??= fail(null, error.message);
}

Powered by Google App Engine
This is Rietveld 408576698