flag: document Nflag function

R=golang-dev, r
CC=golang-dev
https://golang.org/cl/4279065
This commit is contained in:
Fazlul Shahriar 2011-03-20 11:45:43 -07:00 committed by Rob Pike
parent 893e02ab59
commit 19aecba1d5
1 changed files with 1 additions and 0 deletions

View File

@ -289,6 +289,7 @@ func failf(format string, a ...interface{}) {
os.Exit(2)
}
// NFlag returns the number of flags that have been set.
func NFlag() int { return len(flags.actual) }
// Arg returns the i'th command-line argument. Arg(0) is the first remaining argument