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

Unified Diff: src/hydrogen.h

Issue 1313443002: Translate AST to Hydrogen missing position (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/hydrogen.h
diff --git a/src/hydrogen.h b/src/hydrogen.h
index c6953cdad52cca2b4ccd602ff1f67ba6edf950b7..b61013d8801e34008ae9473a9c43c876297c7e6d 100644
--- a/src/hydrogen.h
+++ b/src/hydrogen.h
@@ -1889,6 +1889,9 @@ class HGraphBuilder {
// the SourcePosition assuming that this position corresponds to the
// same function as current position_.
SourcePosition ScriptPositionToSourcePosition(int position) {
+ if (position == RelocInfo::kNoPosition) {
+ return SourcePosition::Unknown();
+ }
SourcePosition pos = position_;
pos.set_position(position - start_position_);
return pos;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698