Re: [go-nuts] "plugin was built with a different version..."

2016-12-16 Thread David Crawshaw
The design doc predates the proposal repository. https://docs.google.com/document/d/1nr-TQHw_er6GOQRsF6T43GGhFDelrAP0NqSS_00RgZQ/edit On Fri, Dec 16, 2016 at 10:08 AM, David Norton wrote: > Thanks, David. Also, is there a proposal / design doc for the plugin pkg > somewhere? I didn't see one in t

Re: [go-nuts] "plugin was built with a different version..."

2016-12-16 Thread David Norton
Thanks, David. Also, is there a proposal / design doc for the plugin pkg somewhere? I didn't see one in the proposal repo. On Wednesday, December 14, 2016 at 2:15:32 PM UTC-5, David Crawshaw wrote: > > The hash is a SHA1 of the package object data, generated by the > linker, cmd/link. The hash i

Re: [go-nuts] "plugin was built with a different version..."

2016-12-14 Thread David Crawshaw
The hash is a SHA1 of the package object data, generated by the linker, cmd/link. The hash is created in the function genhash, and placed in the moduledata in the symtab method. Using a hash of the object data means a plugin has to be compiled against exactly the same package as the host binary.

Re: [go-nuts] "plugin was built with a different version..."

2016-12-14 Thread Ian Lance Taylor
[ +crawshaw ] On Wed, Dec 14, 2016 at 9:03 AM, David Norton wrote: > I'm trying to better understand how the runtime checks package versions when > using the plugin pkg. If there's a mismatch, the following error occurs at > run time: > >> plugin.Open: plugin was built with a different version of

[go-nuts] "plugin was built with a different version..."

2016-12-14 Thread David Norton
I'm trying to better understand how the runtime checks package versions when using the plugin pkg. If there's a mismatch, the following error occurs at run time: plugin.Open: plugin was built with a different version of package ... > That message originates, in the runtime, here