From 19287ca4b6606f7112d4cd6a2d67ac46292f9158 Mon Sep 17 00:00:00 2001 From: David Cournapeau Date: Mon, 9 Nov 2009 03:09:42 +0000 Subject: ENH: put all mandatory headers for npymath in one common header. --- numpy/core/src/npymath/ieee754.c | 7 +------ numpy/core/src/npymath/npy_math.c.src | 7 ------- numpy/core/src/npymath/npy_math_common.h | 8 ++++++++ numpy/core/src/npymath/npy_math_complex.c.src | 8 +------- numpy/core/src/npymath/npy_math_private.h | 3 ++- 5 files changed, 12 insertions(+), 21 deletions(-) create mode 100644 numpy/core/src/npymath/npy_math_common.h (limited to 'numpy/core') diff --git a/numpy/core/src/npymath/ieee754.c b/numpy/core/src/npymath/ieee754.c index 833581eb5..902e8919b 100644 --- a/numpy/core/src/npymath/ieee754.c +++ b/numpy/core/src/npymath/ieee754.c @@ -1,12 +1,7 @@ /* * Low-level routines related to IEEE-754 format */ -#include -#include - -#include "npy_config.h" -#include "numpy/npy_math.h" - +#include "npy_math_common.h" #include "npy_math_private.h" #ifndef HAVE_COPYSIGN diff --git a/numpy/core/src/npymath/npy_math.c.src b/numpy/core/src/npymath/npy_math.c.src index 951668fbb..33c8c0a01 100644 --- a/numpy/core/src/npymath/npy_math.c.src +++ b/numpy/core/src/npymath/npy_math.c.src @@ -53,13 +53,6 @@ * is preserved. * ==================================================== */ - -#include -#include - -#include "npy_config.h" -#include "numpy/npy_math.h" - #include "npy_math_private.h" /* diff --git a/numpy/core/src/npymath/npy_math_common.h b/numpy/core/src/npymath/npy_math_common.h new file mode 100644 index 000000000..0705ea323 --- /dev/null +++ b/numpy/core/src/npymath/npy_math_common.h @@ -0,0 +1,8 @@ +/* + * Common headers needed by every npy math compilation unit + */ +#include +#include + +#include "npy_config.h" +#include "numpy/npy_math.h" diff --git a/numpy/core/src/npymath/npy_math_complex.c.src b/numpy/core/src/npymath/npy_math_complex.c.src index a01d6070a..583328782 100644 --- a/numpy/core/src/npymath/npy_math_complex.c.src +++ b/numpy/core/src/npymath/npy_math_complex.c.src @@ -28,13 +28,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. */ -#include -#include -#include - -#include "config.h" -#include "numpy/npy_math.h" - +#include "npy_math_common.h" #include "npy_math_private.h" /*========================================================== diff --git a/numpy/core/src/npymath/npy_math_private.h b/numpy/core/src/npymath/npy_math_private.h index b0612460c..57055e60f 100644 --- a/numpy/core/src/npymath/npy_math_private.h +++ b/numpy/core/src/npymath/npy_math_private.h @@ -21,8 +21,9 @@ #include #include -#include "config.h" +#include "npy_config.h" #include "numpy/npy_math.h" +#include "numpy/npy_cpu.h" #include "numpy/npy_endian.h" #include "numpy/npy_common.h" -- cgit v1.2.1