public static function match ($reBody) 
    {
        if (strpos($reBody, '#') !== false) {
            $reBody = str_replace('#', '\#', $reBody);
        }
        $regexp = "#{$reBody}#D";
        return function (Field $field) use ($regexp) {
            return (bool)preg_match($regexp, $field->getShorthand());
        };
    }
public static function match ($reBody) 
    {
        if (strpos($reBody, '#') !== false) {
            $reBody = str_replace('#', '\#', $reBody);
        }
        $regexp = "#{$reBody}#D";
        return function (Field $field) use ($regexp) {
            return (bool)preg_match($regexp, $field->getShorthand());
        };
    }
public static function match ( $ reBody ) { if ( strpos ( $ reBody , '#' ) !== false ) { $ reBody = str_replace ( '#' , '\#' , $ reBody ) ; } $ regexp = "#{$reBody}#D" ; return function ( Field $ field ) use ( $ regexp ) { return ( bool ) preg_match ( $ regexp , $ field -> getShorthand ( ) ) ; } ; }
Return predicate that matches a field shorthand against a regular
expression.

@param  string $reBody Body of regular expression
@return callback Predicate
Return predicate that matches a field shorthand against a regular expression .