add hash function
make a hash macro