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

Function ToTypedVector

Libs/flatbuffers/flexbuffers.h:101–110  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

99}
100
101inline Type ToTypedVector(Type t, size_t fixed_len = 0) {
102 FLATBUFFERS_ASSERT(IsTypedVectorElementType(t));
103 switch (fixed_len) {
104 case 0: return static_cast<Type>(t - FBT_INT + FBT_VECTOR_INT);
105 case 2: return static_cast<Type>(t - FBT_INT + FBT_VECTOR_INT2);
106 case 3: return static_cast<Type>(t - FBT_INT + FBT_VECTOR_INT3);
107 case 4: return static_cast<Type>(t - FBT_INT + FBT_VECTOR_INT4);
108 default: FLATBUFFERS_ASSERT(0); return FBT_NULL;
109 }
110}
111
112inline Type ToTypedVectorElementType(Type t) {
113 FLATBUFFERS_ASSERT(IsTypedVector(t));

Callers 2

ScalarVectorFunction · 0.85
CreateVectorFunction · 0.85

Calls 1

IsTypedVectorElementTypeFunction · 0.85

Tested by

no test coverage detected