X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/bed7df33bf28def1f3de010bd983f419f68f3049..47aae2f82171dc72fa3a2e966571b9c86f763667:/include/xbt/misc.h diff --git a/include/xbt/misc.h b/include/xbt/misc.h index 6a5f341ec0..cb1ef332cb 100644 --- a/include/xbt/misc.h +++ b/include/xbt/misc.h @@ -56,6 +56,18 @@ # define XBT_INLINE inline #endif +/* improvable on gcc (by evaluating arguments only once), but wouldn't be portable */ +#ifdef MIN +# undef MIN +#endif +#define MIN(a,b) ((a)<(b)?(a):(b)) + +#ifdef MAX +# undef MAX +#endif +#define MAX(a,b) ((a)>(b)?(a):(b)) + + /* * Function calling convention (not used for now) */