Re: [go-nuts] Re: Relaxing rules on slice comparison: would it make sense?

2016-07-02 Thread as . utf8
Go does not have reference types. As far as I know, the word was purposefully removed from the spec to remove the ambiguity surrounding the word. https://groups.google.com/forum/m/#!topic/golang-dev/926npffb6lA -- You received this message because you are subscribed to the Google Groups

[go-nuts] Re: Help with the the Get url: EOF error (http client)

2016-07-02 Thread Constantin Konstantinidis
I would suggest to first upgrade to 1.6.2 as investigating and support will be complicated by all the changes which occured since then. On Saturday, July 2, 2016 at 11:07:22 AM UTC+2, Pontus Lundin wrote: > > Hi, > > So i have a client running for months doing re-occuring work against a > SOAP

Re: [go-nuts] Re: Relaxing rules on slice comparison: would it make sense?

2016-07-02 Thread Chad
You can do that, but for correctness, I am arguing that it's not what you should expect for slices by default. On Sunday, July 3, 2016 at 3:37:15 AM UTC+2, Florin Pățan wrote: > > I would also expect to compare values not memory locations, generally > that's what I'm interested in comparing. >

[go-nuts] Re: files, readers, byte arrays (slices?), byte buffers and http.requests

2016-07-02 Thread Dave Cheney
The hash is always the same because you ask for the hash value before writing any data through it with io.Copy. -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to

[go-nuts] Re: files, readers, byte arrays (slices?), byte buffers and http.requests

2016-07-02 Thread Sri G
Update: Adding file.Seek(0,0) does fix the issue in Version 2. The uploaded file is the correct size on disk with the correct md5. Without it, the uploaded file which is saved is missing the first 1024 bytes. This makes sense. There is something wrong with the way the md5 is calculated, it

[go-nuts] Re: files, readers, byte arrays (slices?), byte buffers and http.requests

2016-07-02 Thread Sri G
Thanks for the pointer. I also found this helpful Asynchronously Split an io.Reader in Go (golang) « Rodaine but I'm still missing something. Version 1: the uploaded file is 1024 bytes extra at the end (too big): mimebuf :=

[go-nuts] Re: Go-worker or goworker?

2016-07-02 Thread pjmuller
Hi Charl, I need to make the same decision now. What path did you take? On Wednesday, October 30, 2013 at 10:02:28 AM UTC+1, Charl Matthee wrote: > > Hi, > > I am in the process of selecting a resque/sidekiq replacement for a > project and go-workers

[go-nuts] Re: A proposal for generic in go

2016-07-02 Thread Chad
What's generic programming? An implementation of overloading for datastructures and function/methods. The compiler is left in charge of going through the code and specifying which types should actually be used. Go restricts the overloading of function/methods. So we are left with the

[go-nuts] Re: can't install gomobile

2016-07-02 Thread Elias Naur
This is my fault, sorry. Please try https://go-review.googlesource.com/#/c/24720/ then reinstall the gomobile tool and see if that fixes the problem. - elias On Saturday, July 2, 2016 at 4:56:58 AM UTC+2, JM wrote: > > windows pro on 64x. Anyone know what's going on here? Im using the >

Re: [go-nuts] Prevent RTS from creating an OS thread

2016-07-02 Thread Alex Bligh
On 2 Jul 2016, at 05:23, Matt Harden wrote: > Forking is not safe in Go either. Why? Let's assume one knows what one is doing and doesn't try to use channels etc. -- Alex Bligh -- You received this message because you are subscribed to the Google Groups

Re: [go-nuts] Unused var written in closure

2016-07-02 Thread gordon . klaus
More generally, this is https://github.com/golang/go/issues/10989. Such ineffectual assignments can be detected using https://github.com/gordonklaus/ineffassign. An analysis showed that only a small fraction of such were bugs, making the backwards-incompatible language change not worthwhile.

[go-nuts] Re: can't install gomobile

2016-07-02 Thread Constantin Konstantinidis
It seems tha the Android SDK cannot be found. If installed, it should be in your PATH variable. On Saturday, July 2, 2016 at 4:56:58 AM UTC+2, JM wrote: > > windows pro on 64x. Anyone know what's going on here? Im using the > following reference. https://github.com/golang/go/wiki/Mobile >

[go-nuts] Help with the the Get url: EOF error (http client)

2016-07-02 Thread Pontus Lundin
Hi, So i have a client running for months doing re-occuring work against a SOAP web service, suddenly i got the Get url: EOF error and now i am unable to get anything useful back from the server (headers) other than the :EOF There are various threads on this topic

Re: [go-nuts] Re: Relaxing rules on slice comparison: would it make sense?

2016-07-02 Thread Chad
On Saturday, July 2, 2016 at 6:19:56 AM UTC+2, Matt Harden wrote: > > Conceptually, the value of a string is the sequence of bytes it contains, > just like an array of bytes. It doesn't matter that the implementation of > strings looks more like a slice internally. On the other hand the value

Re: [go-nuts] Re: Relaxing rules on slice comparison: would it make sense?

2016-07-02 Thread Chad
On Saturday, July 2, 2016 at 10:23:04 AM UTC+2, Martin Geisler wrote: > > On Fri, Jul 1, 2016 at 4:01 PM, Chad > wrote: > > > > > > On Friday, July 1, 2016 at 3:44:10 PM UTC+2, Martin Geisler wrote: > >> > >> On Fri, Jul 1, 2016 at 12:52 PM, Chad

Re: [go-nuts] Re: Relaxing rules on slice comparison: would it make sense?

2016-07-02 Thread Martin Geisler
On Sat, Jul 2, 2016 at 6:19 AM, Matt Harden wrote: > Conceptually, the value of a string is the sequence of bytes it contains, > just like an array of bytes. It doesn't matter that the implementation of > strings looks more like a slice internally. On the other hand the

Re: [go-nuts] Re: Relaxing rules on slice comparison: would it make sense?

2016-07-02 Thread Martin Geisler
On Fri, Jul 1, 2016 at 4:01 PM, Chad wrote: > > > On Friday, July 1, 2016 at 3:44:10 PM UTC+2, Martin Geisler wrote: >> >> On Fri, Jul 1, 2016 at 12:52 PM, Chad wrote: >> > However, that it's a valid point you raise (re strings) >> > But that's exactly the

[go-nuts] Re: files, readers, byte arrays (slices?), byte buffers and http.requests

2016-07-02 Thread Tamás Gulácsi
2016. július 2., szombat 8:15:19 UTC+2 időpontban Sri G a következőt írta: > > I'm working on receiving uploads through a form. > > The tricky part is validation. > > I attempt to read the first 1024 bytes to check the mime of the file and > then if valid read the rest and hash it and also save

Re: [go-nuts] Prevent RTS from creating an OS thread

2016-07-02 Thread Tamás Gulácsi
What about os/exec with a C shim to setup what needs to be done and start the Go program, passing on given FDs for IPC? -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an