go-capnp icon indicating copy to clipboard operation
go-capnp copied to clipboard

schemas: remove global registry

Open zombiezen opened this issue 7 years ago • 0 comments

Having a global registry of schemas creates problems with vendored copies of go-capnproto2, even if the application doesn't use reflection. I'd like to change APIs that require reflection data to require it as a parameter. I'm thinking that each .capnp.go should have a function that returns all the reflection data and bundles up the transitive dependencies. This approach ought to lend itself to dead-code stripping, which would make binary sizes smaller.

zombiezen avatar Jul 14 '17 20:07 zombiezen