Skip to content
6 changes: 6 additions & 0 deletions arrow/array/dictionary.go
Original file line number Diff line number Diff line change
Expand Up @@ -623,6 +623,12 @@ func (b *dictionaryBuilder) Release() {
}
}

func (b *dictionaryBuilder) UnsafeAppendBoolToBitmap(v bool) {
b.length += 1
b.nulls += 1
b.idxBuilder.UnsafeAppendBoolToBitmap(v)
}

func (b *dictionaryBuilder) AppendNull() {
b.length += 1
b.nulls += 1
Expand Down
9 changes: 9 additions & 0 deletions arrow/array/encoded.go
Original file line number Diff line number Diff line change
Expand Up @@ -386,6 +386,15 @@ func (b *RunEndEncodedBuilder) ContinueRun(n uint64) {
b.addLength(n)
}

func (b *RunEndEncodedBuilder) UnsafeAppendBoolToBitmap(v bool) {
if !v {
b.finishRun()
}
Comment on lines +390 to +392
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this seems incorrect, it could be a run of nulls, couldn't it? And wouldn't the run itself be handled by the value append? I don't think we need to call b.finishRun here


b.values.UnsafeAppendBoolToBitmap(v)
b.addLength(1)
}

func (b *RunEndEncodedBuilder) AppendNull() {
b.finishRun()
b.values.AppendNull()
Expand Down
7 changes: 4 additions & 3 deletions arrow/extensions/extensions.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,12 @@ import (
)

var canonicalExtensionTypes = []arrow.ExtensionType{
NewBool8Type(),
NewUUIDType(),
&OpaqueType{},
&JSONType{},
&OpaqueType{},
&TimestampWithOffsetType{},
&VariantType{},
NewBool8Type(),
NewUUIDType(),
}

func init() {
Expand Down
Loading
Loading