3 ms·
So, I thought this at one point, too. But it turns out that methods is a type alias to an unnamed type, so there's no package level privacy issues: https://gith
by zeeboo 5y ago
So, I thought this at one point, too. But it turns out that methods is a type alias to an unnamed type, so there's no package level privacy issues: https://github.com/protocolbuffers/protobuf-go/blob/v1.26.0/reflect/protoreflect/methods.go#L18 https://github.com/protocolbuffers/protobuf-go/blob/v1.26.0/...
- deleted 5y ago[deleted]
- alecthomas 5y agoOh huh, interesting, I've never seen that done before. I'm struggling to understand what the rationale _for_ doing it is though. Maybe it's to avoid an import cycle?
- neild 5y agoYes, to avoid an import cycle or polluting the protoreflect API documentation with a rather large non-user-facing API surface.