all: apply godoc [Name] link conventions across comments
Every Go-identifier reference in // and /* */ comments now uses
godoc's [Name] linking syntax so pkg.go.dev and `go doc` render
them as clickable cross-references. No behaviour change.
Pattern applied across the tree:
In-package [Foo], [Foo.Bar]
Cross-package [pkg.Foo], [pkg.Foo.Bar]
Stdlib [netip.Prefix], [errors.Is], [context.Context]
Tailscale [tailcfg.MapResponse], [tailcfg.Node.CapMap],
[tailcfg.NodeAttrSuggestExitNode]
Skip rules:
- File:line refs left as plain text
- HuJSON wire keys inside backtick raw strings untouched
- ACL/policy syntax tokens (tag:foo, autogroup:self, ...) not Go
symbols, left as plain text
- JSON/OIDC wire keys, gorm tags, RFC IPv6 placeholders, markdown
link tags, decorative dividers — all left as-is
This commit is contained in:
parent
17236fd284
commit
4cca63155d
124 changed files with 1037 additions and 1011 deletions
|
|
@ -150,7 +150,7 @@ func (s *State) DebugOverview() string {
|
|||
return sb.String()
|
||||
}
|
||||
|
||||
// DebugNodeStore returns debug information about the NodeStore.
|
||||
// DebugNodeStore returns debug information about the [NodeStore].
|
||||
func (s *State) DebugNodeStore() string {
|
||||
return s.nodeStore.DebugString()
|
||||
}
|
||||
|
|
@ -257,7 +257,7 @@ func (s *State) DebugFilter() ([]tailcfg.FilterRule, error) {
|
|||
}
|
||||
|
||||
// DebugRoutes returns the current primary routes information as a
|
||||
// structured object built from the NodeStore snapshot.
|
||||
// structured object built from the [NodeStore] snapshot.
|
||||
func (s *State) DebugRoutes() types.DebugRoutes {
|
||||
debug := types.DebugRoutes{
|
||||
AvailableRoutes: make(map[types.NodeID][]netip.Prefix),
|
||||
|
|
@ -421,7 +421,7 @@ func (s *State) DebugDERPJSON() DebugDERPInfo {
|
|||
return info
|
||||
}
|
||||
|
||||
// DebugNodeStoreJSON returns the actual nodes map from the current NodeStore snapshot.
|
||||
// DebugNodeStoreJSON returns the actual nodes map from the current [NodeStore] snapshot.
|
||||
func (s *State) DebugNodeStoreJSON() map[types.NodeID]types.Node {
|
||||
snapshot := s.nodeStore.data.Load()
|
||||
return snapshot.nodesByID
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue