Static functions and regex cache