Use YY_CHAR macro instead of `char` type in places where processed text is stored
Add test cases for charset support
Add implementation for charset support