| @@ -243,7 +243,7 @@ namespace · 242 unmodified lines |
| 243 | source_ref_t src; | 243 | source_ref_t src; |
| 244 | | 244 | |
| 245 | // Initialize the source with the last state | 245 | // Initialize the source with the last state |
| 246 | src.source_id = fc.last_file; | 246 | src.begin_source_id = fc.last_file; |
| 247 | src.begin_line = fc.last_line; | 247 | src.begin_line = fc.last_line; |
| 248 | src.end_line = fc.last_line; | 248 | src.end_line = fc.last_line; |
| 249 | for (auto i = std::size_t{ 0 }; i < src_parts.size(); ++i) | 249 | for (auto i = std::size_t{ 0 }; i < src_parts.size(); ++i) |
| @@ -274,8 +274,10 @@ namespace · 24 unmodified lines |
| 274 | } | 274 | } |
| 275 | else if (pos[j] == ':') | 275 | else if (pos[j] == ':') |
| 276 | { | 276 | { |
| 277 | assert((i == 0 || src.source_id == v) && "Source position should not change across statements"); | 277 | if (i == 0) |
| 278 | src.source_id = v; | 278 | src.begin_source_id = v; |
| | 279 | |
| | 280 | src.end_source_id = v; |
| 279 | fc.last_file = v; | 281 | fc.last_file = v; |
| 280 | } | 282 | } |
| 281 | } | 283 | } |
| @@ -310,7 +312,7 @@ namespace · 28 unmodified lines |
| 310 | curr_item.debug_statement = std::stoi(pc_item_parts[1]); | 312 | curr_item.debug_statement = std::stoi(pc_item_parts[1]); |
| 311 | | 313 | |
| 312 | // Record the current source and line ID since those are the new default values | 314 | // Record the current source and line ID since those are the new default values |
| 313 | last_source = curr_item.source.source_id; | 315 | last_source = curr_item.source.end_source_id; |
| 314 | last_line = curr_item.source.end_line; | 316 | last_line = curr_item.source.end_line; |
| 315 | | 317 | |
| 316 | pc_table[i] = std::move(curr_item); | 318 | pc_table[i] = std::move(curr_item); |