RUBY-698 Support optional Regex compilation in c ext de/serialization