-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ARROW-1125: Python: Add public C++ API to unwrap PyArrow object #827
Conversation
Change-Id: I333d13016475aee86df57cb83d24eaac1582b8da
Change-Id: Icd7cf12719f143d5d63aa6b7c46af7b6d230b5f0
Change-Id: I43748f8616a3a68f0849c34dca7dc59ade5c1a5a
Change-Id: I127c51caffefac474b6f60781121f5fed5a1fb23
field_ = <Field>(field) | ||
return field_.sp_field | ||
|
||
return shared_ptr[CField]() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this the same as returning nullptr
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, nullptr would only invoke the default constructor and return the same object.
return isinstance(buffer, Buffer) | ||
|
||
|
||
cdef public api shared_ptr[CBuffer] pyarrow_unwrap_buffer(object buffer): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there any reason not to give the arguments stronger types here? Like:
... pyarrow_unwrap_buffer(Buffer buffer)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not allowed in api
functions:
Function declared public or api may not have private types
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1, sweet! I suppose at some point we'll want to set up an "example project" so that we can test these more easily in development
No description provided.