bkietz commented on code in PR #35769:
URL: https://github.com/apache/arrow/pull/35769#discussion_r1376288902
##########
go/arrow/ipc/metadata.go:
##########
@@ -1186,18 +1202,25 @@ func writeDictionaryMessage(mem memory.Allocator, id
int64, isDelta bool, size,
return writeMessageFB(b, mem, flatbuf.MessageHeaderDictionaryBatch,
dictFB, bodyLength)
}
-func recordToFB(b *flatbuffers.Builder, size, bodyLength int64, fields
[]fieldMetadata, meta []bufferMetadata, codec flatbuf.CompressionType)
flatbuffers.UOffsetT {
+func recordToFB(b *flatbuffers.Builder, size, bodyLength int64, fields
[]fieldMetadata, meta []bufferMetadata, codec flatbuf.CompressionType,
variadicCounts []int64) flatbuffers.UOffsetT {
fieldsFB := writeFieldNodes(b, fields,
flatbuf.RecordBatchStartNodesVector)
metaFB := writeBuffers(b, meta, flatbuf.RecordBatchStartBuffersVector)
var bodyCompressFB flatbuffers.UOffsetT
if codec != -1 {
bodyCompressFB = writeBodyCompression(b, codec)
}
+ flatbuf.RecordBatchStartVariadicBufferCountsVector(b,
len(variadicCounts))
+ for i := len(variadicCounts) - 1; i >= 0; i-- {
+ b.PrependInt64(variadicCounts[i])
+ }
+ vcFB := b.EndVector(len(variadicCounts))
+
Review Comment:
I think it probably would be preferable to leave the variadic buffer counts
absent rather than empty if none are necessary
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]