refactor UTF32 checker