vmware / go-vcloud-director

Golang SDK for VMware Cloud Director
Other
80 stars 76 forks source link

Replace 'takeStringPointer', 'takeIntAddress', 'takeBoolPointer' with generic 'addrOf' #571

Closed Didainius closed 1 year ago

Didainius commented 1 year ago

Before Go had generics, we used type based functions to get addresses of variables.

These were functions in govcd/api.go:

The bbove functions are now replaced by generic function func addrOf[T any](variable T) *T.

The content of this PR is "search and replace". No user facing changes.