Generalize the char hash function to signed/unsigned/plan char.