match

package
v0.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 26, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package match implements the -type glob filtering: parsing the comma-separated pattern list and testing a type name against it.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MatchAny

func MatchAny(patterns []string, name string) bool

MatchAny reports whether name matches any glob pattern (path.Match syntax). An empty name (anonymous struct) never matches a non-empty pattern set; invalid patterns are treated as non-matching rather than fatal.

func ParsePatterns

func ParsePatterns(s string) []string

ParsePatterns splits a comma-separated value into trimmed, non-empty glob patterns. Empty input yields nil (meaning "match everything").

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL