Skip to content

Commit

Permalink
feature: make type-registry ON by default
Browse files Browse the repository at this point in the history
  • Loading branch information
widmogrod committed May 11, 2024
1 parent b6af66f commit b818e43
Show file tree
Hide file tree
Showing 9 changed files with 520 additions and 9 deletions.
2 changes: 1 addition & 1 deletion cmd/mkunion/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ func main() {
},
&cli.BoolFlag{
Name: "type-registry",
Value: false,
Value: true,
},
},
Action: func(c *cli.Context) error {
Expand Down
2 changes: 1 addition & 1 deletion example/state/model.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package state

import "time"

//go:generate go run ../../cmd/mkunion/main.go --type-registry
//go:generate go run ../../cmd/mkunion/main.go

//go:tag mkunion:"Command"
type (
Expand Down
2 changes: 1 addition & 1 deletion example/tree.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package example

//go:generate go run ../cmd/mkunion/main.go --type-registry
//go:generate go run ../cmd/mkunion/main.go

//go:tag mkunion:"Tree"
type (
Expand Down
2 changes: 1 addition & 1 deletion f/datas.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package f

//go:generate go run ../cmd/mkunion --type-registry
//go:generate go run ../cmd/mkunion

//go:tag mkunion:"Either,serde"
type (
Expand Down
6 changes: 3 additions & 3 deletions x/projection/projection.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"time"
)

//go:generate go run ../../cmd/mkunion/main.go -v -type-registry
//go:generate go run ../../cmd/mkunion/main.go -v

var (
ErrStateAckNilOffset = errors.New("cannot acknowledge nil offset")
Expand All @@ -21,7 +21,7 @@ const (
KeySystemWatermark = "watermark"
)

//go:tag mkunion:"Data,noserde"
//go:tag mkunion:"Data"
type (
Record[A any] struct {
Key string
Expand Down Expand Up @@ -559,7 +559,7 @@ func DoSink[A any](ctx PushAndPull[A, any], f func(*Record[A]) error) error {
}
}

//go:tag mkunion:"Either,noserde"
//go:tag mkunion:"Either"
type (
Left[A, B any] struct {
Left A
Expand Down
Loading

0 comments on commit b818e43

Please sign in to comment.