00001 /* 00002 * Copyright 1995, University Corporation for Atmospheric Research 00003 * See top level COPYRIGHT file for copying and redistribution conditions. 00004 */ 00005 /* $Id: fbits.h,v 1.2 1995/05/26 20:46:46 davis Exp $ */ 00006 00007 #ifndef _FBITS_H_ 00008 #define _FBITS_H_ 00009 00010 /* 00011 * Macros for dealing with flag bits. 00012 */ 00013 #define fSet(t, f) ((t) |= (f)) 00014 #define fClr(t, f) ((t) &= ~(f)) 00015 #define fIsSet(t, f) ((t) & (f)) 00016 #define fMask(t, f) ((t) & ~(f)) 00017 00018 /* 00019 * Propositions 00020 */ 00021 /* a implies b */ 00022 #define pIf(a,b) (!(a) || (b)) 00023 /* a if and only if b, use == when it makes sense */ 00024 #define pIff(a,b) (((a) && (b)) || (!(a) && !(b))) 00025 00026 #endif /*!FBITS_H_*/
1.4.4