[go-nuts] Re: Can't explain Golang benchmarks

2017-07-16 Thread Zohaib Sibte Hassan
Awesome :) got similar results. So channels are slower for pubsub. I am surprised so far, with the efficiency going down as the cores go up (heck reminds me of that Node.js single core meme). Please tell me I am wrong here, is there any other more efficient approach? On Sunday, July 16, 2017 a

[go-nuts] Re: [Go2] toward-go2

2017-07-16 Thread Nathan Kerr
The active work for Go2 right now is gathering experience reports . Most of the changes resulting from these reports will land in Go1.x. It is expected that Go2 will only have a few major changes that will not be compatible with Go1. It is also possible

Re: [go-nuts] Re: [Ann] Generating go struct from json/yaml

2017-07-16 Thread Tong Sun
Oh, sorry, I meant to begin the message with, Thanks Aditya, On Mon, Jul 17, 2017 at 12:43 AM, Tong Sun wrote: Is the `subStruct` feature working as expected? > > You can try testing on the SmartyStreets.json > > fi

Re: [go-nuts] Re: [Ann] Generating go struct from json/yaml

2017-07-16 Thread Tong Sun
Is the `subStruct` feature working as expected? You can try testing on the SmartyStreets.json file. Thanks. On Sun, Jul 16, 2017 at 8:15 PM, Aditya Mukerjee wrote: > Hi Tong, > > Glad to see you're finding gojson us

Re: [go-nuts] Programming paradigm.

2017-07-16 Thread Rob Pike
This might help. https://talks.golang.org/2012/splash.article -rob On Mon, Jul 17, 2017 at 3:13 AM, Mayank Acharya wrote: > Dear all, > I am new to Go language. > > I searched a lot to understand it's paradigm structure but still not > getting clear idea about that. > > Please if anyone can e

[go-nuts] [Ann] Interactive Goroutine Dump Analysis Tool

2017-07-16 Thread linuxerwang
https://github.com/linuxerwang/goroutine-inspect This is a very useful tool which helped us find channel blocking and deadlocks in real Golang services. With this tool the analysis time can be reduced from one hour to a few minutes. If you have any idea to improve it, please open an issue or ev

[go-nuts] [Go2] toward-go2

2017-07-16 Thread Gert
There are so many https://github.com/golang/go/issues?q=is%3Aissue+is%3Aopen+go2+label%3AGo2 proposals already I can barely figure out if feature x y or z is already asked. Can we have a Go2 branch / milestone please? PS now that you announced toward-go2 you are going to actively work on Go2 r

[go-nuts] Programming paradigm.

2017-07-16 Thread Mayank Acharya
Dear all, I am new to Go language. I searched a lot to understand it's paradigm structure but still not getting clear idea about that. Please if anyone can explain, go language follows which programming paradigm with some clear example for understanding. I really appreciate responses. Thank y

[go-nuts] Re: [Ann] Generating go struct from json/yaml

2017-07-16 Thread Aditya Mukerjee
Hi Tong, Glad to see you're finding gojson useful. Let us know if you have suggestions; if there are improvements which would be helpful for people in general, we'd be happy to merge them upstream. On Sunday, July 16, 2017 at 10:28:09 AM UTC-4, Tong Sun wrote: > > Hi, > > I've started to impr

[go-nuts] Re: Can't explain Golang benchmarks

2017-07-16 Thread peterGo
Your latest benchmarks are invalid. In your benchmarks, replace b.StartTimer() with b.ResetTimer(). Simply run benchmarks. Don't run race detectors. Don't run profilers. For example, $ go version go version devel +504deee Sun Jul 16 03:57:11 2017 + linux/amd64 $ go test -run=! -bench=. -ben

Re: [go-nuts] json.Unmarshal and numbers: go 1.7 vs go 1.8

2017-07-16 Thread Traun Leyden
Ok thanks! Btw looks like the copy/paste turned 2^64 -> 264 On Saturday, July 15, 2017 at 11:34:18 AM UTC-7, Ian Lance Taylor wrote: > > On Sat, Jul 15, 2017 at 11:20 AM, Traun Leyden > wrote: > > > > On go 1.7, I'm seeing a difference in behavior between json.Unmarshal > and > > json.Deco

[go-nuts] Re: Can't explain Golang benchmarks

2017-07-16 Thread Zohaib Sibte Hassan
Thanks for pointing issues out I updated my code to get rid of race conditions (nothing critical I was always doing reader-writer race). Anyhow I updated my code on https://gist.github.com/maxpert/f3c405c516ba2d4c8aa8b0695e0e054e. Still doesn't explain the new results: $> go test -race -run=!

Re: [go-nuts] Re: Named or unnamed struct initialisation? What is best practice?

2017-07-16 Thread Dan Kortschak
Yes, trailing zero-size elements affect the size. https://play.golang.org/p/Ox0FJX3C5V https://github.com/golang/go/commit/6f07ac2f280847ee0346b871b23cab90869f84a4 On Tue, 2017-07-11 at 20:34 -0700, Rader wrote: > I found the position of `[0]byte` in the struct matters.  >  type bar2 struct { >

Re: [go-nuts] Re: Named or unnamed struct initialisation? What is best practice?

2017-07-16 Thread Dan Kortschak
Both are used. On Wed, 2017-07-12 at 11:43 +, Matthew Zimmerman wrote: > Why not use struct{}?  Is what is recommended for maps to notate a > set > (only the keys mean something). -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscr

Re: [go-nuts] Shiny

2017-07-16 Thread Ged Wed
have a look here: https://docs.google.com/document/d/1mXev7TyEnvM4t33lnqoji-x7EqGByzh4RpE4OqEZck4/edit# -- 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 golang-nu

[go-nuts] Re: Can't explain Golang benchmarks

2017-07-16 Thread peterGo
When you have data races the results are undefined. $ go version go version devel +dd81c37 Sat Jul 15 05:43:45 2017 + linux/amd64 $ go test -race -run=! -bench=. -benchmem -cpu=1,2,4,8 pubsub_test.go == WARNING: DATA RACE Read at 0x00c4200140c0 by goroutine 18: command-line-a

[go-nuts] [Ann] Generating go struct from json/yaml

2017-07-16 Thread Tong Sun
Hi, I've started to improve the tools that generates go struct definitions from json or yaml documents, https://github.com/go-jsonfile/gojson#cli-update: Using gojson is now deprecated. You can still install and use it, but better use jsonfiddle j2s

[go-nuts] Can't explain Golang benchmarks

2017-07-16 Thread zohaib . hassan
I have been spending my day over implementing an efficient PubSub system. I had implemented one before using channels, and I wanted to benchmark that against sync.Cond. Here is the quick and dirty test that I put together https://gist.github.com/maxpert/f3c405c516ba2d4c8aa8b0695e0e054e. Now my

Re: [go-nuts] Shiny

2017-07-16 Thread Elias Naur
Hi, I had plans to work on a GUI library that follows many of the design choices from Flutter. In particular, I'd like to experiment with immediate mode drawing and a layout manager based on Cassowary. As backend I plan to avoid too much upfront work and bind to Skia. I'd be very interested in

Re: [go-nuts] Web UI library in pure Go?

2017-07-16 Thread Mandolyte
https://github.com/gopherjs/gopherjs On Saturday, July 15, 2017 at 5:16:34 PM UTC-4, ohir wrote: > > On Sat, 15 Jul 2017 09:30:39 -0700 (PDT) > Leff Ivanov > wrote: > > > Is there something like Vaadin, GWT, ZK in Golang world? I mean > something > > to do web UIs in pure Go without the need t

Re: [go-nuts] Shiny

2017-07-16 Thread Joe Blue
Hey All gophers that want a GUI toolkit... We are doing a bring up that is planned to work on all desktops, mobile and embedded. Support the following app types:: forms, 2d surface and 3d surface. Will have: Material design components, virtual keyboard, cut and paste, audio and video capture