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

Unified Diff: runtime/vm/parser.cc

Issue 382993003: More PcDescriptor cleanups. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 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
« no previous file with comments | « runtime/vm/parser.h ('k') | runtime/vm/raw_object.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/parser.cc
===================================================================
--- runtime/vm/parser.cc (revision 38237)
+++ runtime/vm/parser.cc (working copy)
@@ -330,6 +330,16 @@
}
+// Each try in this function gets its own try index.
+// See definition of RawPcDescriptors::PcDescriptor.
+int16_t Parser::AllocateTryIndex() {
+ if (!Utils::IsInt(16, last_used_try_index_ - 1)) {
+ ReportError("too many nested try statements");
+ }
+ return last_used_try_index_++;
+}
+
+
void Parser::SetScript(const Script& script, intptr_t token_pos) {
script_ = script.raw();
tokens_iterator_.SetStream(
« no previous file with comments | « runtime/vm/parser.h ('k') | runtime/vm/raw_object.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698