From 3ad9aafbd02e23c0d4a8fdb41f02ff25fa03746a Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Fri, 22 Jan 2016 06:57:38 -0800 Subject: Reduce header pollution caused by mpi.h. * eval.c: include that was previously coming via "mpi.h". * mpi/mpi.c: Includes of , and moved here. * mpi/mpi.h: Remove include of , and . Keeping for now; needed for CHAR_BIT. * mpi/mplogic.c: Needs --- mpi/mpi.c | 9 ++++++++- mpi/mpi.h | 6 ------ mpi/mplogic.c | 3 +++ 3 files changed, 11 insertions(+), 7 deletions(-) (limited to 'mpi') diff --git a/mpi/mpi.c b/mpi/mpi.c index 0b5e622f..c52e47bd 100644 --- a/mpi/mpi.c +++ b/mpi/mpi.c @@ -10,11 +10,18 @@ */ #include "config.h" -#include "mpi.h" +#if MP_IOFUNC +#include +#include +#endif #include #include #include #include +#include "mpi.h" +#if MP_ARGCHK == 2 +#include +#endif #define MAX(A, B) ((A) > (B) ? (A) : (B)) #define MIN(A, B) ((A) < (B) ? (A) : (B)) diff --git a/mpi/mpi.h b/mpi/mpi.h index ac2929d3..0e000643 100644 --- a/mpi/mpi.h +++ b/mpi/mpi.h @@ -16,11 +16,6 @@ #define MP_IOFUNC 1 #endif -#if MP_IOFUNC -#include -#include -#endif - #include #define MP_NEG 1 @@ -60,7 +55,6 @@ #if MP_ARGCHK == 1 #define ARGCHK(X,Y) {if(!(X)){return (Y);}} #elif MP_ARGCHK == 2 -#include #define ARGCHK(X,Y) assert(X) #else #define ARGCHK(X,Y) /* */ diff --git a/mpi/mplogic.c b/mpi/mplogic.c index 2d1cf7bf..eb44b866 100644 --- a/mpi/mplogic.c +++ b/mpi/mplogic.c @@ -11,6 +11,9 @@ #include "config.h" #include "mplogic.h" +#if MP_ARGCHK == 2 +#include +#endif #include /* Some things from the guts of the MPI library we make use of... */ -- cgit v1.2.3