Assuming
perl -P works on your system, you could define macros. Here is a short example:
#!/usr/bin/perl -P
# set this to the bit masks
#define ONE 1
#define TWO 2
#define THREE 3
#define FOUR 4
print "bitwise AND (ONE & FOUR)=", ONE & FOUR, "\n";
print "bitwise AND (ONE & THREE)=", ONE & THREE, "\n";
then running the script will produce:
$ ./script.pl
bitwise AND (ONE & FOUR)=0
bitwise AND (ONE & THREE)=1
If perl -P gives an error where it can't find cpp, you can probably copy the one from your gcc dist into a directory into your path.
--
hiseldl