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

Unified Diff: runtime/vm/intermediate_language.h

Issue 23691024: If a rethrow is encountered in the catch block, then its handler must be marked that it needs stack… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 4 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: runtime/vm/intermediate_language.h
===================================================================
--- runtime/vm/intermediate_language.h (revision 26933)
+++ runtime/vm/intermediate_language.h (working copy)
@@ -1986,13 +1986,17 @@
class ReThrowInstr : public TemplateInstruction<0> {
public:
- explicit ReThrowInstr(intptr_t token_pos) : token_pos_(token_pos) { }
+ // 'cacth_try_index' can be CatchClauseNode::kInvalidTryIndex if the
Ivan Posva 2013/08/31 00:06:23 cactus?
srdjan 2013/08/31 00:18:06 Done.
+ // rethrow has been artifically generated by the parser.
+ ReThrowInstr(intptr_t token_pos, intptr_t catch_try_index)
+ : token_pos_(token_pos), catch_try_index_(catch_try_index) {}
DECLARE_INSTRUCTION(ReThrow)
virtual intptr_t ArgumentCount() const { return 2; }
intptr_t token_pos() const { return token_pos_; }
+ intptr_t catch_try_index() const { return catch_try_index_; }
virtual bool CanDeoptimize() const { return true; }
@@ -2002,6 +2006,7 @@
private:
const intptr_t token_pos_;
+ const intptr_t catch_try_index_;
DISALLOW_COPY_AND_ASSIGN(ReThrowInstr);
};

Powered by Google App Engine
This is Rietveld 408576698