From 7c5bb6541a820dd4721358226ca3815d94736863 Mon Sep 17 00:00:00 2001 From: Stan Hu Date: Mon, 2 Jul 2012 14:00:45 -0700 Subject: Cast enum vaules to integers and cast them back where appropraite to prevent mixed enumeration type compiler warnings --- pb.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'pb.h') diff --git a/pb.h b/pb.h index d030d9e3..61696a4f 100644 --- a/pb.h +++ b/pb.h @@ -195,7 +195,7 @@ typedef enum { #define pb_arraysize(st, m) (pb_membersize(st, m) / pb_membersize(st, m[0])) #define pb_delta(st, m1, m2) ((int)offsetof(st, m1) - (int)offsetof(st, m2)) #define pb_delta_end(st, m1, m2) (offsetof(st, m1) - offsetof(st, m2) - pb_membersize(st, m2)) -#define PB_LAST_FIELD {0,0,0,0} +#define PB_LAST_FIELD {0,(pb_type_t) 0,0,0} #endif -- cgit 1.2.3-korg