pub fn compare_field_bytes(
a_buf: &[u8],
a_range: (usize, usize),
b_buf: &[u8],
b_range: (usize, usize),
) -> OrderingExpand description
Compare two MessagePack values by their decoded content.
Comparison order:
- Null < Bool < Number < Instant < String < Binary < Array < Map < Ext
- Within numbers: exact numeric order; integers (
uint64included) never round through f64, an integer against a float compares exactly, and NaN sorts above every number and equals NaN - Within instants: by kind (UTC before naive), then signed epoch micros
- Within strings: lexicographic on raw bytes (valid UTF-8 guarantees byte order = Unicode code-point order for ASCII/Latin-1)
- Fallback: raw byte comparison