-
Notifications
You must be signed in to change notification settings - Fork 426
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
pkg/crd: support validation on type alias to basic types
Without the type Alias being its own type (Go 1.22 see gotypesalias), in localNamedToSchema, the link is missing. [ Upstream port of cilium/controller-tools@d944debcff34 ("Support type aliasing to basic types") ] Previously, validation schema generation was skipped on a type alias: type A = B Whereas, a new type was fine: type A B This commit implements support for generating validation schemas for type aliases to basic types, i.e. string, int, etc. Co-authored-by: Chris Tarazi <tarazichris@gmail.com> Signed-off-by: Mahe Tardy <mahe.tardy@gmail.com>
- Loading branch information
1 parent
d0b7b74
commit 7587d2c
Showing
3 changed files
with
37 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters