Skip to content

Commit

Permalink
Add missing functions to flagset
Browse files Browse the repository at this point in the history
  • Loading branch information
posener committed Nov 27, 2019
1 parent e63b7a9 commit 3627b98
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions compflag/compflag.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,13 +53,16 @@ func (fs *FlagSet) Parse(args []string) error {
return (*flag.FlagSet)(fs).Parse(args)
}

func (fs *FlagSet) Visit(fn func(*flag.Flag)) { (*flag.FlagSet)(fs).Visit(fn) }
func (fs *FlagSet) VisitAll(fn func(*flag.Flag)) { (*flag.FlagSet)(fs).VisitAll(fn) }
func (fs *FlagSet) Arg(i int) string { return (*flag.FlagSet)(fs).Arg(i) }
func (fs *FlagSet) Args() []string { return (*flag.FlagSet)(fs).Args() }
func (fs *FlagSet) NArg() int { return (*flag.FlagSet)(fs).NArg() }
func (fs *FlagSet) NFlag() int { return (*flag.FlagSet)(fs).NFlag() }
func (fs *FlagSet) Name() string { return (*flag.FlagSet)(fs).Name() }
func (fs *FlagSet) Visit(fn func(*flag.Flag)) { (*flag.FlagSet)(fs).Visit(fn) }
func (fs *FlagSet) VisitAll(fn func(*flag.Flag)) { (*flag.FlagSet)(fs).VisitAll(fn) }
func (fs *FlagSet) Arg(i int) string { return (*flag.FlagSet)(fs).Arg(i) }
func (fs *FlagSet) Args() []string { return (*flag.FlagSet)(fs).Args() }
func (fs *FlagSet) NArg() int { return (*flag.FlagSet)(fs).NArg() }
func (fs *FlagSet) NFlag() int { return (*flag.FlagSet)(fs).NFlag() }
func (fs *FlagSet) Name() string { return (*flag.FlagSet)(fs).Name() }
func (fs *FlagSet) PrintDefaults() { (*flag.FlagSet)(fs).PrintDefaults() }
func (fs *FlagSet) Lookup(name string) *flag.Flag { return (*flag.FlagSet)(fs).Lookup(name) }
func (fs *FlagSet) Parsed() bool { return (*flag.FlagSet)(fs).Parsed() }

// Complete performs bash completion if needed.
func (fs *FlagSet) Complete() {
Expand Down

0 comments on commit 3627b98

Please sign in to comment.