Skip to content

Commit

Permalink
clone: remove deprecated method
Browse files Browse the repository at this point in the history
Signed-off-by: Vicent Marti <vmg@strn.cat>
  • Loading branch information
vmg committed Jan 27, 2023
1 parent a8dd609 commit c793337
Show file tree
Hide file tree
Showing 8 changed files with 2 additions and 222 deletions.
20 changes: 0 additions & 20 deletions conformance/internal/conformance/conformance_vtproto.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 2 additions & 7 deletions features/clone/clone.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
package clone

import (
"github.com/planetscale/vtprotobuf/generator"
"google.golang.org/protobuf/compiler/protogen"
"google.golang.org/protobuf/reflect/protoreflect"

"github.com/planetscale/vtprotobuf/generator"
)

const (
cloneName = "CloneVT"
cloneMessageName = "CloneMessageVT"
cloneGenericName = "CloneGenericVT"
)

var (
Expand Down Expand Up @@ -152,11 +152,6 @@ func (p *clone) generateCloneMethodsForMessage(proto3 bool, message *protogen.Me
p.P(`return m.`, cloneName, `()`)
p.P(`}`)
p.P()
p.P(`// Deprecated: use `, cloneMessageName, ` instead`)
p.P(`func (m *`, ccTypeName, `) `, cloneGenericName, `() `, protoPkg.Ident("Message"), ` {`)
p.P(`return m.`, cloneMessageName, `()`)
p.P(`}`)
p.P()
}

// body generates the code for the actual cloning logic of a structure containing the given fields.
Expand Down
5 changes: 0 additions & 5 deletions testproto/pool/pool_vtproto.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 0 additions & 20 deletions testproto/pool/pool_with_slice_reuse_vtproto.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit c793337

Please sign in to comment.