Repository navigation
fix: keep every option in a WRITETABLE option series - #21
Merged
Merged
Conversation
The batch parser read the WRITETABLE option token once and took only its first 2-letter code + sign, silently dropping the rest of a multi-option series. The legacy writeTableBatch (batch.java) reads one option token and chomps it in 2-letter code + sign chunks until it is empty, so "AS+AR+" is a series of two options. Mirror the legacy chomp loop: AS+AR+ now yields +AS and +AR, a sign-less series tail is an error instead of a silent drop, and the single-option and empty-options forms are unchanged.
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.
Bug
<WRITETABLE> (1,5,AS+AR+,"f.txt")silently drops every optionafter the first: the parser read the option token once and took
only its first 2-letter code + sign.
Legacy contract
The legacy writeTableBatch (batch.java) reads one option token and
chomps it in 2-letter code + sign chunks until it is empty, so
AS+AR+is a series of two options. The manual: "Multiple optionsform one series".
Fix
Mirror the legacy chomp loop in rta_parse_write_table:
AS+AR+yields+ASand+ARAS+AR) is a BatchError instead of asilent drop
AR+) and empty-options (,,) forms unchangedVerification
and three-option series and the sign-less error case.
test_engine_suppress and test_engine_run_arb all pass.