fix: keep mapping-key guidance off native hot paths - #16
Merged
Conversation
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.
What changed
src/encode.rsexactly to the publishedv0.3.0b4native source.Why
The tag-time
0.3.0b5guard established regressions in all four typed/functional encode endpoints while untyped encode remained non-inferior. The only remaining native source difference from b4 was the cold mapping-key error text insideencode.rs. This change removes that native layout perturbation entirely; the error factory is called only after an encode error has already occurred.Performance evidence that rejected the prior candidate
R 4.4.2 analyzed 36 randomized baseline/current pairs across the preregistered 22-endpoint family using paired log process means and simultaneous Bonferroni intervals:
The lower bound exceeds the +3% margin for each endpoint, so these are established regressions. No unchanged-candidate rerun was performed.
Validation
git diff v0.3.0b4 -- src: emptyuv run pytest -q tests/test_native_encode_types.py: 40 passedmake qualify: 488 Python tests passed, 11 skipped; 43 Rust tests passed; official TOON corpus 538/538; G2 zero-intermediate-container proof passedThe next performance decision belongs to the release workflow’s R-owned guard on verified release wheels.