Code cleanup + improvements to character class parsing
 improvements to character class parsing