You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Variant] VariantMetadata is allowed to contain the empty string (#7956)
# Which issue does this PR close?
- Follow-up to #7901
# Rationale for this change
- #7934
Introduced a minor regression, in (accidentally?) forbidding the empty
string as a dictionary key. Fix the bug and simplify the code a bit
further while we're at it.
# What changes are included in this PR?
Revert the unsorted dictionary check back to what it had been (it just
uses `Iterator::is_sorted_by` now, instead of
`primitive.slice::is_sorted_by`).
Remove the redundant offset monotonicity check from the ordered
dictionary path, relying on the fact that string slice extraction will
anyway fail if the offsets are not monotonic. Improve the error message
now that it does double duty.
# Are these changes tested?
New unit tests for dictionaries containing the empty string. As a side
effect, we now have at least a little coverage for sorted dictionaries
-- somehow, I couldn't find any existing unit test that creates a sorted
dictionary??
# Are there any user-facing changes?
No
---------
Co-authored-by: Andrew Lamb <andrew@nerdnetworks.org>
0 commit comments