mirror of
https://github.com/google/flatbuffers.git
synced 2026-06-02 04:04:19 +00:00
Fixing an assert in flexbuffers CreateVector (#4824)
An assert was blocking the creation of typedvectors. It was wrongly checking for limited types even though vector was not of fixedTyped.
This commit is contained in:
committed by
Wouter van Oortmerssen
parent
6bfa107f4e
commit
7c824ef690
@@ -1443,7 +1443,7 @@ class Builder FLATBUFFERS_FINAL_CLASS {
|
||||
}
|
||||
// If you get this assert, your fixed types are not one of:
|
||||
// Int / UInt / Float / Key.
|
||||
FLATBUFFERS_ASSERT(IsTypedVectorElementType(vector_type));
|
||||
FLATBUFFERS_ASSERT(!fixed || IsTypedVectorElementType(vector_type));
|
||||
auto byte_width = Align(bit_width);
|
||||
// Write vector. First the keys width/offset if available, and size.
|
||||
if (keys) {
|
||||
|
||||
Reference in New Issue
Block a user