From d8faaf29fa88537518f5cf923cdb51e3f80507e3 Mon Sep 17 00:00:00 2001 From: Paul Brossier Date: Fri, 23 Sep 2016 07:54:04 +0200 Subject: [PATCH] python/ext/aubiomodule.c: remove extern --- python/ext/aubio-types.h | 26 +++++++++++++------------- python/ext/aubiomodule.c | 5 ++--- python/lib/gen_external.py | 2 +- 3 files changed, 16 insertions(+), 17 deletions(-) diff --git a/python/ext/aubio-types.h b/python/ext/aubio-types.h index f67b2dad..95cb095b 100644 --- a/python/ext/aubio-types.h +++ b/python/ext/aubio-types.h @@ -51,32 +51,32 @@ #define Py_TYPE(ob) (((PyObject*)(ob))->ob_type) #endif -extern PyTypeObject Py_cvecType; +PyTypeObject Py_cvecType; PyObject * new_py_fvec(uint_t length); PyObject * new_py_cvec(uint_t length); PyObject * new_py_fmat(uint_t height, uint_t length); // defined in aubio-proxy.c -extern int PyAubio_IsValidVector (PyObject *input); +int PyAubio_IsValidVector (PyObject *input); -extern PyObject *PyAubio_CFvecToArray (fvec_t * self); -extern int PyAubio_ArrayToCFvec (PyObject * self, fvec_t *out); +PyObject *PyAubio_CFvecToArray (fvec_t * self); +int PyAubio_ArrayToCFvec (PyObject * self, fvec_t *out); -extern int PyAubio_PyCvecToCCvec (PyObject *input, cvec_t *i); +int PyAubio_PyCvecToCCvec (PyObject *input, cvec_t *i); -extern PyObject *PyAubio_CFmatToArray (fmat_t * self); -extern int PyAubio_ArrayToCFmat (PyObject *input, fmat_t *out); +PyObject *PyAubio_CFmatToArray (fmat_t * self); +int PyAubio_ArrayToCFmat (PyObject *input, fmat_t *out); // hand written wrappers -extern PyTypeObject Py_filterType; +PyTypeObject Py_filterType; -extern PyTypeObject Py_filterbankType; +PyTypeObject Py_filterbankType; -extern PyTypeObject Py_fftType; +PyTypeObject Py_fftType; -extern PyTypeObject Py_pvocType; +PyTypeObject Py_pvocType; -extern PyTypeObject Py_sourceType; +PyTypeObject Py_sourceType; -extern PyTypeObject Py_sinkType; +PyTypeObject Py_sinkType; diff --git a/python/ext/aubiomodule.c b/python/ext/aubiomodule.c index 616dc759..46c196ee 100644 --- a/python/ext/aubiomodule.c +++ b/python/ext/aubiomodule.c @@ -74,9 +74,8 @@ static char Py_min_removal_doc[] = "" "\n" ">>> min_removal(a)"; -extern void add_generated_objects ( PyObject *m ); -extern void add_ufuncs ( PyObject *m ); -extern int generated_types_ready(void); +void add_ufuncs ( PyObject *m ); +int generated_types_ready(void); static PyObject * Py_alpha_norm (PyObject * self, PyObject * args) diff --git a/python/lib/gen_external.py b/python/lib/gen_external.py index 533116eb..a86687d2 100644 --- a/python/lib/gen_external.py +++ b/python/lib/gen_external.py @@ -224,7 +224,7 @@ void add_generated_objects ( PyObject *m ) print ("wrote %s" % output_file ) sources_list.append(output_file) - objlist = "".join(["extern PyTypeObject Py_%sType;\n" % p for p in lib]) + objlist = "".join(["PyTypeObject Py_%sType;\n" % p for p in lib]) out = """// generated list of objects created with gen_external.py #include -- 2.11.0