Repository navigation
sed: restart R command readers for separate input files - #666
Himanshu-singh04 wants to merge 3 commits into
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #666 +/- ##
==========================================
+ Coverage 95.25% 95.43% +0.18%
==========================================
Files 14 14
Lines 7500 7735 +235
Branches 442 460 +18
==========================================
+ Hits 7144 7382 +238
+ Misses 355 352 -3
Partials 1 1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
| context.line_number = 0; | ||
| reset_latched_address_ranges(&mut context.range_commands); | ||
|
|
||
| if context.separate { |
There was a problem hiding this comment.
is this if needed? on the first file the readers are still unopened anyway
There was a problem hiding this comment.
Good catch. I removed the unnecessary first-file check in dc25158; the named readers now reset directly under the existing per-file reset guard.
Merging this PR will degrade performance by 3.86%2 warnings
Warning Please fix the performance issues or acknowledge them on CodSpeed. Performance Changes
Tip Investigate this regression by commenting Comparing |
| context.line_number = 0; | ||
| reset_latched_address_ranges(&mut context.range_commands); | ||
|
|
||
| for reader in context.named_readers.values() { |
There was a problem hiding this comment.
could you please rename it? it shadows reader above
There was a problem hiding this comment.
Renamed the loop variable to named_reader in d6befd4 so it no longer shadows the input reader. The focused R-reader test and formatting check pass.
|
I checked the two remaining failed checks. The focused Codecov reports one uncovered changed line: the CodSpeed reports the same Would you prefer a matched-environment rerun or an acknowledgement of the CodSpeed result? For the Codecov line, is there a preferred way to handle coverage mapping when the loop body is already reported as covered? I don't want to add a redundant test or alter the working loop just to change the report. |
Fixes #653.
Restart shared
Rcommand readers when processing each separate input file. This gives each file the first line of the named file under-sand-i, while retaining the existing shared cursor for ordinary processing.Add an integration regression covering both
-soutput and-ifile contents. It failed before the fix and passes afterward.Validation:
cargo test --offline --quiet;cargo fmt --check;cargo clippy --offline --all-targets -- -D warnings;git diff --check.