Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/docopt/docopt.go
/ newOptional
Function
newOptional
docopt.go:767–769 ·
view source on GitHub ↗
(pl ...*pattern)
Source
from the content-addressed store, hash-verified
765
}
766
767
func
newOptional(pl ...*pattern) *pattern {
768
return
newBranchPattern(patternOptionAL, pl...)
769
}
770
771
func
newOptionsShortcut() *pattern {
772
var
p pattern
Callers
8
parseAtom
Function · 0.85
TestPatternFlat
Function · 0.85
TestParsePattern
Function · 0.85
TestOptionalMatch
Function · 0.85
TestOneOrMoreMatch
Function · 0.85
TestBasicPatternMatching
Function · 0.85
TestPatternEither
Function · 0.85
TestPatternFixIdentities2
Function · 0.85
Calls
1
newBranchPattern
Function · 0.85
Tested by
7
TestPatternFlat
Function · 0.68
TestParsePattern
Function · 0.68
TestOptionalMatch
Function · 0.68
TestOneOrMoreMatch
Function · 0.68
TestBasicPatternMatching
Function · 0.68
TestPatternEither
Function · 0.68
TestPatternFixIdentities2
Function · 0.68