Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pattern Modifier in YangType #271

Open
steiler opened this issue Aug 2, 2024 · 1 comment
Open

Pattern Modifier in YangType #271

steiler opened this issue Aug 2, 2024 · 1 comment

Comments

@steiler
Copy link

steiler commented Aug 2, 2024

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.

@steiler
Copy link
Author

steiler commented Aug 5, 2024

@wenovus, @robshakir any advice?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant