Refactor codes using REGEXP_CLASS define.
Merge pull request #1365 from suzukaze/refactor-using-REGEXP_CLASS

Refactor codes using REGEXP_CLASS define.