Variant HHVM_FUNCTION(preg_replace_callback, const Variant& pattern, const Variant& callback, const Variant& subject, int limit /* = -1 */, VRefParam count /* = null */) { if (!f_is_callable(callback)) { raise_warning("Not a valid callback function %s", callback.toString().data()); return empty_string_variant(); } return preg_replace_impl(pattern, callback, subject, limit, count, true, false); }
Variant HHVM_FUNCTION(preg_filter, const Variant& pattern, const Variant& callback, const Variant& subject, int limit /* = -1 */, VRefParam count /* = null */) { return preg_replace_impl(pattern, callback, subject, limit, count, false, true); }
Variant f_preg_replace_callback(CVarRef pattern, CVarRef callback, CVarRef subject, int limit /* = -1 */, VRefParam count /* = null */) { return preg_replace_impl(pattern, callback, subject, limit, count, true); }
Variant HHVM_FUNCTION(preg_replace, const Variant& pattern, const Variant& replacement, const Variant& subject, int limit /* = -1 */, VRefParam count /* = null */) { return preg_replace_impl(pattern, replacement, subject, limit, count, false, false); }
Variant f_preg_replace(CVarRef pattern, CVarRef replacement, CVarRef subject, int limit /* = -1 */, VRefParam count /* = null */) { return preg_replace_impl(pattern, replacement, subject, limit, count, false); }