Skip to content

Commit

Permalink
MAINT: remove unused simple_capsule_dtor() from npy_3kcompat.h
Browse files Browse the repository at this point in the history
This removes a lot of build warnings when including this file.
  • Loading branch information
rgommers committed Jan 19, 2014
1 parent bbb4918 commit b449dfd
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 12 deletions.
6 changes: 6 additions & 0 deletions doc/release/1.9.0-notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,12 @@ to an array via `np.array`.
If the `overwrite_input` option is used the input is only partially instead of
fully sorted.

npy_3kcompat.h header change
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The unused ``simple_capsule_dtor`` function has been removed from
``npy_3kcompat.h``. Note that this header is not meant to be used outside of
numpy; other projects should be using their own copy of this file when needed.


New Features
============
Expand Down
12 changes: 0 additions & 12 deletions numpy/core/include/numpy/npy_3kcompat.h
Original file line number Diff line number Diff line change
Expand Up @@ -391,12 +391,6 @@ NpyCapsule_Check(PyObject *ptr)
return PyCapsule_CheckExact(ptr);
}

static NPY_INLINE void
simple_capsule_dtor(PyObject *cap)
{
PyArray_free(PyCapsule_GetPointer(cap, NULL));
}

#else

static NPY_INLINE PyObject *
Expand Down Expand Up @@ -430,12 +424,6 @@ NpyCapsule_Check(PyObject *ptr)
return PyCObject_Check(ptr);
}

static NPY_INLINE void
simple_capsule_dtor(void *ptr)
{
PyArray_free(ptr);
}

#endif

/*
Expand Down

0 comments on commit b449dfd

Please sign in to comment.