Skip to content

Commit

Permalink
apacheGH-40386: [Python] Fix except clauses (apache#40387)
Browse files Browse the repository at this point in the history
### Rationale for this change

See apache#40386, these changes are necessary for compatibility with Cython 3.0.9

### What changes are included in this PR?

This PR removes unnecessary `noexcept` clauses.

### Are these changes tested?

Covered by existing builds.

### Are there any user-facing changes?

No.

* GitHub Issue: apache#40386

Authored-by: Vyas Ramasubramani <[email protected]>
Signed-off-by: Felipe Oliveira Carvalho <[email protected]>
  • Loading branch information
vyasr authored and thisisnic committed Mar 8, 2024
1 parent e1b21c6 commit 3b86b08
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions python/pyarrow/types.pxi
Original file line number Diff line number Diff line change
Expand Up @@ -5462,7 +5462,7 @@ cdef void pycapsule_schema_deleter(object schema_capsule) noexcept:

free(schema)

cdef object alloc_c_schema(ArrowSchema** c_schema) noexcept:
cdef object alloc_c_schema(ArrowSchema** c_schema):
c_schema[0] = <ArrowSchema*> malloc(sizeof(ArrowSchema))
# Ensure the capsule destructor doesn't call a random release pointer
c_schema[0].release = NULL
Expand All @@ -5481,7 +5481,7 @@ cdef void pycapsule_array_deleter(object array_capsule) noexcept:

free(array)

cdef object alloc_c_array(ArrowArray** c_array) noexcept:
cdef object alloc_c_array(ArrowArray** c_array):
c_array[0] = <ArrowArray*> malloc(sizeof(ArrowArray))
# Ensure the capsule destructor doesn't call a random release pointer
c_array[0].release = NULL
Expand All @@ -5500,7 +5500,7 @@ cdef void pycapsule_stream_deleter(object stream_capsule) noexcept:

free(stream)

cdef object alloc_c_stream(ArrowArrayStream** c_stream) noexcept:
cdef object alloc_c_stream(ArrowArrayStream** c_stream):
c_stream[0] = <ArrowArrayStream*> malloc(sizeof(ArrowArrayStream))
# Ensure the capsule destructor doesn't call a random release pointer
c_stream[0].release = NULL
Expand Down

0 comments on commit 3b86b08

Please sign in to comment.