Re: [go-nuts] Is it safe to modify any part of a pointer?

2016-10-18 Thread Joshua Liebow-Feeser
On Tue, Oct 18, 2016 at 4:19 PM, Ian Lance Taylor wrote: > On Tue, Oct 18, 2016 at 3:13 PM, Joshua Liebow-Feeser > wrote: > > > > On Tue, Oct 18, 2016 at 2:53 PM, Ian Lance Taylor > wrote: > >> > >> On Tue, Oct 18, 2016 at 2:45 PM, Joshua Liebow-Feeser

Re: [go-nuts] Is it safe to modify any part of a pointer?

2016-10-18 Thread Joshua Liebow-Feeser
On Tue, Oct 18, 2016 at 2:53 PM, Ian Lance Taylor wrote: > On Tue, Oct 18, 2016 at 2:45 PM, Joshua Liebow-Feeser > wrote: > > > > On Tue, Oct 18, 2016 at 2:40 PM, Joshua Liebow-Feeser > > wrote: > >> > >> > >> > >> On Tue, Oct 18, 20

Re: [go-nuts] Is it safe to modify any part of a pointer?

2016-10-18 Thread Joshua Liebow-Feeser
On Tue, Oct 18, 2016 at 2:40 PM, Joshua Liebow-Feeser wrote: > > > On Tue, Oct 18, 2016 at 2:16 PM, Ian Lance Taylor wrote: > >> On Tue, Oct 18, 2016 at 12:30 PM, Joshua Liebow-Feeser >> wrote: >> > >> > I'm playing around with implementing a wai

Re: [go-nuts] Is it safe to modify any part of a pointer?

2016-10-18 Thread Joshua Liebow-Feeser
On Tue, Oct 18, 2016 at 2:16 PM, Ian Lance Taylor wrote: > On Tue, Oct 18, 2016 at 12:30 PM, Joshua Liebow-Feeser > wrote: > > > > I'm playing around with implementing a wait-free channel in the runtime > > package, and as part of this, it'd be really nice t

Re: [go-nuts] Re: Is it safe to modify any part of a pointer?

2016-10-18 Thread Joshua Liebow-Feeser
On Oct 18, 2016 12:42 PM, "adonovan via golang-nuts" < golang-nuts@googlegroups.com> wrote: > > On Tuesday, 18 October 2016 15:30:36 UTC-4, Joshua Liebow-Feeser wrote: >> >> are there any bits in a pointer which, when modified, won't mess with the GC? &g

[go-nuts] Is it safe to modify any part of a pointer?

2016-10-18 Thread Joshua Liebow-Feeser
Hi All, I'm playing around with implementing a wait-free channel in the runtime package, and as part of this, it'd be really nice to have double-word compare-and-swap (CAS). Barring that, however, for my purposes, it would actually be fine to have a one-word value that encodes both a pointer an

Re: [go-nuts] Build constraints exclude go:binary-only-package directive?

2016-08-22 Thread Joshua Liebow-Feeser
Done: https://github.com/golang/go/issues/16841 On Monday, August 22, 2016 at 3:19:48 PM UTC-7, Ian Lance Taylor wrote: > > On Mon, Aug 22, 2016 at 2:57 PM, Joshua Liebow-Feeser > wrote: > > > > According to the documentation, the //go:binary-only-package directive >

[go-nuts] Build constraints exclude go:binary-only-package directive?

2016-08-22 Thread Joshua Liebow-Feeser
Hi All, According to the documentation , the //go:binary-only-package directive is only used when the file is "not excluded by build constraints." However, I have the following source: // +build !build_source //go:binary-only-package

Re: [go-nuts] Define method on scope-local type

2016-08-19 Thread Joshua Liebow-Feeser
than the package scope > > But if you raised this point here in order to propose a language change, > I'll quietly slip into the shadows! > > > Paul > > > On 19 August 2016 at 19:38, Joshua Liebow-Feeser wrote: > >> Hi Paul, >> >> I think you mea

Re: [go-nuts] Define method on scope-local type

2016-08-19 Thread Joshua Liebow-Feeser
Hey Paul, I think those are interesting ideas, but my concern about scope-local methods extends beyond just the methods of the sort.Interface interface; I was just using that as an example. The same complaint applies for any type used only within a given scope that needs to implement any interf

[go-nuts] Define method on scope-local type

2016-08-18 Thread Joshua Liebow-Feeser
Hi All, TL;DR: While you can define types inside of functions (or scopes inside of functions), those types can't have methods on them. This limits the usability of this feature. I propose that we add the ability to define methods on scope-local types. This came up while discussing the limitati

[go-nuts] Define method on scope-local type

2016-08-18 Thread Joshua Liebow-Feeser
Hi All, TL;DR: While you can define types inside of functions (or scopes inside of functions), those types can't have methods on them. This limits the usability of this feature. I propose that we add the ability to define methods on scope-local types. This came up while discussing the limitati

Re: [go-nuts] Re: importer.Default not able to find packages in $GOPATH

2016-06-17 Thread Joshua Liebow-Feeser
'go install' worked; thanks a ton! I'll also take a look at the other stuff you mentioned because I'm curious about the details. On Fri, Jun 17, 2016 at 5:15 PM, adonovan via golang-nuts < golang-nuts@googlegroups.com> wrote: > On Friday, 17 June 2016 15:21:55 UTC-

[go-nuts] importer.Default not able to find packages in $GOPATH

2016-06-17 Thread Joshua Liebow-Feeser
Hi All, I'm trying to use the go/* packages to parse and type check Go source code. I've downloaded github.com/coreos/etcd to test this on, and I'm currently trying it out in the etcdserver subdirectory. When I run 'go build' everything works fine, but when I try to type check, none of the impo