replace character class