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

Unified Diff: pkg/compiler/lib/src/parser/element_listener.dart

Issue 2671653005: Improve handling of parser stack overflows. (Closed)
Patch Set: Created 3 years, 11 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 | « no previous file | pkg/front_end/lib/src/fasta/parser/error_kind.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/parser/element_listener.dart
diff --git a/pkg/compiler/lib/src/parser/element_listener.dart b/pkg/compiler/lib/src/parser/element_listener.dart
index f7109264fa334857cd60fe7ded35b8e6667a7232..35cca095b21509c1ec6b8a7834969877383100be 100644
--- a/pkg/compiler/lib/src/parser/element_listener.dart
+++ b/pkg/compiler/lib/src/parser/element_listener.dart
@@ -681,6 +681,11 @@ class ElementListener extends Listener {
errorCode = MessageKind.UNTERMINATED_TOKEN;
break;
+ case ErrorKind.StackOverflow:
+ errorCode = MessageKind.GENERIC;
+ arguments = {"text": "Stack overflow."};
+ break;
+
case ErrorKind.Unspecified:
errorCode = MessageKind.GENERIC;
break;
« no previous file with comments | « no previous file | pkg/front_end/lib/src/fasta/parser/error_kind.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698