From 8eaa2902162e145cd07a9427ec99ab0ca85aa35a Mon Sep 17 00:00:00 2001 From: Karl Schultz Date: Fri, 18 Oct 2002 17:02:00 +0000 Subject: Add casts to quiet compiler warnings. --- src/mesa/main/macros.h | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) (limited to 'src/mesa/main/macros.h') diff --git a/src/mesa/main/macros.h b/src/mesa/main/macros.h index 37f4f16f26..4fc93936ac 100644 --- a/src/mesa/main/macros.h +++ b/src/mesa/main/macros.h @@ -1,4 +1,4 @@ -/* $Id: macros.h,v 1.29 2002/07/09 01:22:50 brianp Exp $ */ +/* $Id: macros.h,v 1.30 2002/10/18 17:02:00 kschultz Exp $ */ /* * Mesa 3-D graphics library @@ -113,6 +113,27 @@ do { \ (DST)[3] = (SRC)[3]; \ } while (0) +#define COPY_2V_CAST( DST, SRC, CAST ) \ +do { \ + (DST)[0] = (CAST)(SRC)[0]; \ + (DST)[1] = (CAST)(SRC)[1]; \ +} while (0) + +#define COPY_3V_CAST( DST, SRC, CAST ) \ +do { \ + (DST)[0] = (CAST)(SRC)[0]; \ + (DST)[1] = (CAST)(SRC)[1]; \ + (DST)[2] = (CAST)(SRC)[2]; \ +} while (0) + +#define COPY_4V_CAST( DST, SRC, CAST ) \ +do { \ + (DST)[0] = (CAST)(SRC)[0]; \ + (DST)[1] = (CAST)(SRC)[1]; \ + (DST)[2] = (CAST)(SRC)[2]; \ + (DST)[3] = (CAST)(SRC)[3]; \ +} while (0) + #if defined(__i386__) #define COPY_4UBV(DST, SRC) \ do { \ -- cgit v1.2.3