[go-nuts] [ANN] sqlx for cassandra gocqlx v1.0.0 released

2018-05-25 Thread michal
GoCQLX is a general purpose extensions to golang's Cassandra driver gocql. With gocqlx you can bind query parameters from maps and structs, use named query parameters (:identifier) and scan query results into structs and slices. It comes with a fluent and flexible CQL query builder and a

[go-nuts] Re: Freeing memory of a cgo library

2018-05-25 Thread jake6502
Looks like you are on windows. I have worked a lot with windows, C/C++ and go, but never actually built a go dll. But, since no one else has picked this up, maybe I can help. 1. I'm not sure what "the cgo" library means here? Do you have this: cpp<->go(dll)<->c(cgo)? Or something else. 2.

[go-nuts] Re: Freeing memory of a cgo library

2018-05-25 Thread alex . rou . sg
Nope, not ATM. Go only works with gcc, even the dlls are made with gcc. There is a issue on that and it seems like there is some progress but it isn't clear when it will be usable. https://github.com/golang/go/issues/20982 Also note that even if Go uses msvc, you would still have issues freeing

[go-nuts] Re: Freeing memory of a cgo library

2018-05-25 Thread Liron Levy
Gotcha :) Thanks for the info, guess i will have to find a way around it then. At least i now know there is no real way to do what i wanted so that close this door :) -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this

Re: [go-nuts] go tool trace: --> filtering/modifying

2018-05-25 Thread Neven Miculinić
Hey, in the end I've used opencensus which has the same features as go's spans, but it's designed for distributed tracing. I already have multiple backend support, which supports more advanced filtering options than chrome://tracings's catapult viewer. Thanks, Neven Miculinić On Tue, 8 May

[go-nuts] Re: Freeing memory of a cgo library

2018-05-25 Thread alex . rou . sg
Memory allocated by one C/C++ runtime must and can only be freed through the same runtime. This is not a Go/cgo problem, this is normal C/C++ behavior. So by mixing gcc and msvc there are at least 2 C/C++ runtimes. Even mixing different compiler versions might cause issues. On Saturday, 26 May

[go-nuts] guru on Windows limits referrers to the same package

2018-05-25 Thread Torsten Uhlmann
Hi, I just had to move my GO environment from Linux to Windows 10. I set up everything as simple as possible (GOROOT = C:\go, GOPATH = %USERPROFILE%\go) to test the installation. For an IDE I use vscode. When trying to see all referrers of a struct type vscode only shows references within the

Re: [go-nuts] time.Now takes ~3758 ns/op, is that normal?

2018-05-25 Thread Rany
Thank you! I think at this point it is very clear that this problem is due to some weird alternative normal of my computer. D: I will found another time to test it on another OS. 在 2018年05月25日 15:40, mfriedenha...@gmail.com 写道: Hello, I downloaded your gist and these are my results:

[go-nuts] Re: how to reuse getters and setters of two different versions of struct ? [interface{}/generics]

2018-05-25 Thread alex . rou . sg
This is what interfaces are for. You have: type GetKeyer interface { GetKey1() string GetKey2() string } Then to use it: https://play.golang.org/p/rvLsWCIBuxe You still have to implement GetKey1 and GetKey2 on each struct, but you can access them through a common interface without

[go-nuts] Re: Freeing memory of a cgo library

2018-05-25 Thread Liron Levy
Hey Jake, First if all thanks for the willing to help. Cgo is the built-in tool in go of building c libraries (see: https://golang.org/cmd/cgo/) What I basically do is that I have a go code, which i build into c library (dll), i.e, i insert the go code onto the cgo mechine then get .h and

Re: [go-nuts] go tool trace: --> filtering/modifying

2018-05-25 Thread Hyang-Ah Hana Kim
cool. if the granularity and the info open census provides is sufficient for your use case that’s the right way. go tool trace is for analyzing interaction between go runtime and the application. On Fri, May 25, 2018 at 1:22 PM Neven Miculinić wrote: > Hey, > > in

[go-nuts] Re: how to reuse getters and setters of two different versions of struct ? [interface{}/generics]

2018-05-25 Thread anilkuncham
Thank you Alex for your quick reply. I figured it out. Using Interfaces is the right way to solve this. On Friday, 25 May 2018 12:08:01 UTC-7, alex@gmail.com wrote: > > This is what interfaces are for. > > You have: > type GetKeyer interface { > GetKey1() string > GetKey2() string >

[go-nuts] Future of Frozen Packages

2018-05-25 Thread John Unland
So I'm going thru some of the Github issues, I'm wondering what will become of these packages that are frozen in the stdlib: - log/syslog (Implements logging facilities for *nix operating systems) - net/smtp (Implements RFC 5321) - net/rpc (Implements remote procedure calls for Go-Only

Re: [go-nuts] Type dependency graphs?

2018-05-25 Thread Rohit Jain
https://github.com/TrueFurby/go-callvis This is a really neat tool On Wednesday, May 23, 2018, Patrik Iselind wrote: > Hi guys, > > I'm after a way to visualize all types in my project spanning multiple > packages. This includes both which types are composed of which

[go-nuts] Does Golang need the innovation of C++ move semantics too

2018-05-25 Thread Li Jianhua
1. Why does C++ introduce move semantics anyway? What problems is it going to solve? 2. How come Golang, C (Without ++) don’t have that move semantics yet? Will they need the move soon? -- You received this message because you are subscribed to the Google Groups "golang-nuts" group.

[go-nuts] time.Now takes ~3758 ns/op, is that normal?

2018-05-25 Thread mfriedenhagen
Hello, I downloaded your gist and these are my results: ~/.Trash$ $ curl -s -O https://gist.githubusercontent.com/reinit/82608ab20e5aac3bd3c1eb5a8f78d23c/raw/bbc6fdb1ad0f137a66a986fe2af931ea477b5625/time_now_test.go ; go version ; go test -bench . go version go1.10.2 darwin/amd64 goos: darwin