Skip to content

Conversation

@kou
Copy link
Member

@kou kou commented Nov 27, 2017

No description provided.

Copy link
Member

@wesm wesm left a comment

Choose a reason for hiding this comment

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

+1, with a small question

}
};
std::shared_ptr<arrow::DataType>
shared_arrow_data_type(arrow_data_type, NullDeleter());
Copy link
Member

Choose a reason for hiding this comment

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

Is there a possibility of this object being deleted while the result value of this function is still alive?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes. It may be deleted because this dictionary array doesn't have reference to this object.

I created the meaningless shared_ptr because the current GArrowDataType requires std::shared_ptr<arrow::DataType>. It's just an implementation detail. I can change GArrowDataType to support raw arrow::DataType * but it increases complexity. So I chose this approach.

Copy link
Member

Choose a reason for hiding this comment

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

OK, thank you

@wesm wesm closed this in 5220283 Nov 29, 2017
@kou kou deleted the glib-dictionary-array branch November 30, 2017 00:35
wesm pushed a commit that referenced this pull request Dec 1, 2017
Author: Kouhei Sutou <kou@clear-code.com>

Closes #1365 from kou/glib-dictionary-array and squashes the following commits:

83bfa13 [Kouhei Sutou] [GLib] Add GArrowDictionaryArray
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants