You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Brad Fitzpatrick
86f42ea87b
cmd/cloner, cmd/viewer: handle named map/slice types with Clone/View methods
...
The cloner and viewer code generators didn't handle named types
with basic underlying types (map/slice) that have their own Clone
or View methods. For example, a type like:
type Map map[string]any
func (m Map) Clone() Map { ... }
func (m Map) View() MapView { ... }
When used as a struct field, the cloner would descend into the
underlying map[string]any and fail because it can't clone the any
(interface{}) value type. Similarly, the viewer would try to create
a MapFnOf view and fail.
Fix the cloner to check for a Clone method on the named type
before falling through to the underlying type handling.
Fix the viewer to check for a View method on named map/slice types,
so the type author can provide a purpose-built safe view that
doesn't leak raw any values. Named map/slice types without a View
method fall through to normal handling, which correctly rejects
types like map[string]any as unsupported.
Updates tailscale/corp#39502 (needed by tailscale/corp#39594 )
Change-Id: Iaef0192a221e02b4b8e409c99ef8398090327744
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2 weeks ago
..
ace
all: remove AUTHORS file and references to it
3 months ago
art
all: use Go 1.26 things, run most gofix modernizers
1 month ago
bakedroots
all: remove AUTHORS file and references to it
3 months ago
batching
cmd/vet: add subtestnames analyzer; fix all existing violations
2 weeks ago
captivedetection
all: use Go 1.26 things, run most gofix modernizers
1 month ago
connectproxy
all: remove AUTHORS file and references to it
3 months ago
dns
cmd/cloner, cmd/viewer: handle named map/slice types with Clone/View methods
2 weeks ago
dnscache
all: remove AUTHORS file and references to it
3 months ago
dnsfallback
all: remove AUTHORS file and references to it
3 months ago
flowtrack
all: remove AUTHORS file and references to it
3 months ago
ipset
all: use `bart.Lite` instead of `bart.Table` where appropriate
3 weeks ago
ktimeout
all: remove AUTHORS file and references to it
3 months ago
memnet
all: remove AUTHORS file and references to it
3 months ago
netaddr
all: remove AUTHORS file and references to it
3 months ago
netcheck
cmd/vet: add subtestnames analyzer; fix all existing violations
2 weeks ago
neterror
all: use Go 1.26 things, run most gofix modernizers
1 month ago
netkernelconf
all: remove AUTHORS file and references to it
3 months ago
netknob
all: remove AUTHORS file and references to it
3 months ago
netmon
cmd/vet: add subtestnames analyzer; fix all existing violations
2 weeks ago
netns
netns: add Android callback to bind socket to network ( #18915 )
1 month ago
netstat
all: remove AUTHORS file and references to it
3 months ago
netutil
all: use Go 1.26 things, run most gofix modernizers
1 month ago
netx
all: remove AUTHORS file and references to it
3 months ago
packet
net,tsnet: fix the capitalisation of "Wireshark"
3 weeks ago
ping
all: remove AUTHORS file and references to it
3 months ago
portmapper
all: remove AUTHORS file and references to it
3 months ago
porttrack
net/porttrack: change magic listen address format for Go 1.26
1 month ago
proxymux
all: remove AUTHORS file and references to it
3 months ago
routetable
netns,wgengine: add OpenBSD support to netns via an rtable
2 months ago
sockopts
all: remove AUTHORS file and references to it
3 months ago
socks5
all: use Go 1.26 things, run most gofix modernizers
1 month ago
sockstats
all: remove AUTHORS file and references to it
3 months ago
speedtest
cmd/vet: add subtestnames analyzer; fix all existing violations
2 weeks ago
stun
cmd/vet: add subtestnames analyzer; fix all existing violations
2 weeks ago
stunserver
all: use Go 1.26 things, run most gofix modernizers
1 month ago
tcpinfo
all: remove AUTHORS file and references to it
3 months ago
tlsdial
net,tsnet: fix the capitalisation of "Wireshark"
3 weeks ago
tsaddr
all: remove AUTHORS file and references to it
3 months ago
tsdial
all: remove AUTHORS file and references to it
3 months ago
tshttpproxy
cmd/vet: add subtestnames analyzer; fix all existing violations
2 weeks ago
tstun
tailcfg,ipn/ipnlocal: regulate netmap caching via a node attribute ( #19117 )
2 weeks ago
udprelay
cmd/vet: add subtestnames analyzer; fix all existing violations
2 weeks ago
wsconn
all: remove AUTHORS file and references to it
3 months ago