You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: match.go
    path of file: ./repos/sealer/vendor/github.com/pkg/sftp
    
    the code of the file until where you have to start completion: package sftp

import (
	"path"
	"strings"
)

// ErrBadPattern indicates a globbing pattern was malformed.
var ErrBadPattern = path.ErrBadPattern

// Match reports whether name matches the shell pattern.
//
// This is an alias for path.Match from the standard library,
// offered so that callers need not import the path package.
// For details, see https://golang.org/pkg/path/#Match.
func Match(pattern, name string) (matched bool, err error) {
	return path.Match(pattern, name)
}

// detect if byte(char) is path separator
func isPathSeparator(c by
    
func (c *Client) Glob(pattern string) (matches []string, err error) {
	if !hasMeta(pattern) {
		file, err := c.Lstat(pattern)
		if err != nil {
			return nil, nil
		}
		dir, _ := Split(pattern)
		dir = cleanGlobPath(dir)
		return []string{Join(dir, file.Name())}, nil
	}

	dir, file := Split(pattern)
	dir = cleanGlobPath(dir)

	if !hasMeta(dir) {
		return c.glob(dir, file, nil)
	}

	// Prevent infinite recursion. See issue 15879.
	if dir == pattern {
		return nil, ErrBadPattern
	}

	var m []string
	m, err = c.Glob(dir)
	if err != nil {
		return
	}
	for _, d := range m {
		matches, err = c.glob(d, file, matches)
		if err != nil {
			return
		}
	}
	return
}