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

Unified Diff: pkg/front_end/lib/src/fasta/vm.dart

Issue 2739213004: Improve detection of compile-time errors. (Closed)
Patch Set: dartfmt Created 3 years, 9 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
« no previous file with comments | « pkg/front_end/lib/src/fasta/source/source_loader.dart ('k') | pkg/front_end/test/fasta/compile.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/front_end/lib/src/fasta/vm.dart
diff --git a/pkg/front_end/lib/src/fasta/vm.dart b/pkg/front_end/lib/src/fasta/vm.dart
index d9f7de810af59cefe73f1b9e9a3d2836067d213a..9247c4a38da9668898f447a346a3f7128a75bc4f 100644
--- a/pkg/front_end/lib/src/fasta/vm.dart
+++ b/pkg/front_end/lib/src/fasta/vm.dart
@@ -12,7 +12,7 @@ import 'dart:io' show File, Platform;
import 'dart:typed_data' show Uint8List;
-import 'outline.dart' as fasta;
+import 'fasta.dart' as fasta;
/// Compilation status codes.
///
@@ -35,7 +35,11 @@ abstract class CompilationResult {
factory CompilationResult.ok(Uint8List bytes) = _CompilationOk;
- factory CompilationResult.error(List<String> errors) = _CompilationError;
+ factory CompilationResult.errors(List<String> errors) = _CompilationError;
+
+ factory CompilationResult.error(String error) {
+ return new _CompilationError(<String>[error]);
+ }
factory CompilationResult.crash(Object exception, StackTrace stack) =
_CompilationCrash;
« no previous file with comments | « pkg/front_end/lib/src/fasta/source/source_loader.dart ('k') | pkg/front_end/test/fasta/compile.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698