Version 1.1.1#8
Merged
Merged
Conversation
The C parser had separate warning emission sites from the Ruby parser and had drifted: empty_value / duplicate_key dropped the key name (and duplicate_key the resolution strategy), and duplicate_key reported the wrong column. Bring the C messages up to the Ruby contract, and attribute the duplicate-key warning to the duplicate member's value position (a parallel offset array on the value stack) so the line/col match on single-line, multiline, and nested objects. Adds spec/warning_parity_spec.rb: per-type [true,false] message+line+col checks plus a cross-path equality test over every warning type — the coverage that was missing and would have caught this drift. Suite 1,097 green, 100% coverage. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8 +/- ##
=======================================
Coverage 99.83% 99.83%
=======================================
Files 7 7
Lines 1193 1193
=======================================
Hits 1191 1191
Misses 2 2 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
…ost) The duplicate-key warning position array (pptr) is only read when an on_warning handler is present, so allocate and write it only then. Parses without a handler — the common case — now do no extra allocation or per-push store; pptr stays NULL. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
unifying warnings