MCPcopy Create free account
hub / github.com/TombEngine/TombEngine / KeyOffsetCompare

Class KeyOffsetCompare

Libs/flatbuffers/flexbuffers.h:1607–1617  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1605 BitWidth force_min_bit_width_;
1606
1607 struct KeyOffsetCompare {
1608 explicit KeyOffsetCompare(const std::vector<uint8_t> &buf) : buf_(&buf) {}
1609 bool operator()(size_t a, size_t b) const {
1610 auto stra =
1611 reinterpret_cast<const char *>(flatbuffers::vector_data(*buf_) + a);
1612 auto strb =
1613 reinterpret_cast<const char *>(flatbuffers::vector_data(*buf_) + b);
1614 return strcmp(stra, strb) < 0;
1615 }
1616 const std::vector<uint8_t> *buf_;
1617 };
1618
1619 typedef std::pair<size_t, size_t> StringOffset;
1620 struct StringOffsetCompare {

Callers 1

flexbuffers.hFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected