goyang
goyang copied to clipboard
Pattern Modifier in YangType
Via #241 the Modifier field was added to the Pattern struct.
However, the YangType is still lacking the modifier information.
Unfortunately the Pattern field is a []string
(https://github.com/openconfig/goyang/blob/master/pkg/yang/yangtype.go#L249).
The conversion / resolution is done here: https://github.com/openconfig/goyang/blob/master/pkg/yang/types.go#L370-L377
I want to implement the modifier in the YangType. Should the pattern field remain a []string or should it become a
type ytPattern struct {
pattern string
inverted bool
}
Which would be a breaking change.