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

Unified Diff: src/interpreter/source-position-table.cc

Issue 1855913002: [interpreter] add some expression positions. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 8 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: src/interpreter/source-position-table.cc
diff --git a/src/interpreter/source-position-table.cc b/src/interpreter/source-position-table.cc
index 221d8a52ed8d5f621b5c11b1adc27d3047fd840d..c4e2425264a91c33e29ad60c5f3748215980ea36 100644
--- a/src/interpreter/source-position-table.cc
+++ b/src/interpreter/source-position-table.cc
@@ -140,7 +140,10 @@ void SourcePositionTableBuilder::AddEntry(
// Don't encode a new entry if this bytecode already has a source position
// assigned.
if (candidate_.bytecode_offset == entry.bytecode_offset) {
- if (on_duplicate == OVERWRITE_DUPLICATE) candidate_ = entry;
+ if ((!candidate_.is_statement && entry.is_statement) ||
+ on_duplicate == OVERWRITE_DUPLICATE) {
+ candidate_ = entry;
+ }
return;
}

Powered by Google App Engine
This is Rietveld 408576698