Re: [go-nuts] go get failing In Mac 10.11.4

2016-06-21 Thread Krzysztof Kowalczyk
My guess is that's because Mac filesystem is case preserving but not case-sensitive, meaning that in mac os "floRest" and "florest" is the same file/directory while on linux those are 2 distinct files. (you can configure mac filesystem to be case-sensitive as well, but that's not the default).

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

2016-06-21 Thread Matt Ho
I think I have to agree with most of the posters here about generics. In theory, I miss them. However, in practice, I find that there are usually only a few times during the course of a project where I wish I had generics. And then after writing a few lines of code to do what the generic

Re: [go-nuts] How to hide command line argument from ps

2016-06-21 Thread Hoping White
Thanks for all the replies. I agree that there is a better way to do the security jobs. I ask this question just for curiosity, to find out if there is a equivalence way to do this in golang. From all the replies I assume there is a no. > 在 2016年6月21日,下午10:39,Matt Harden

[go-nuts] A proposal for generic in go

2016-06-21 Thread Marcus Yip
On Tuesday, June 21, 2016 at 2:56:01 PM UTC-4, Axel Wagner wrote: The issue is, that a "KeyValuePair" (no matter if you implemented it via generics or like you mention via interfaces) i -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To

Re: [go-nuts] GoMobile window size always 800x800

2016-06-21 Thread Andy Brewer
OK, it sounds like it's more complicated than I thought to expose those screen dimensions to the API. There are a good (and growing) number of designers like me who code and the gomobile tool is too barebones at the moment to be productive for testing UI across multiple screen size or horizontal

Re: [go-nuts] Go test to run over sub packages?

2016-06-21 Thread gabriel . kopley
Hi Ian, thanks for the confirmation! It turns out that the cause of this behavior is that I had followed the instructions at https://github.com/karlseguin/the-little-go-book/blob/9f95b4405760fe9d24d4f9b7da93889cc9306f58/en/go.md#getting-started and symlinked thus: `$ ln -s

Re: [go-nuts] Go test to run over sub packages?

2016-06-21 Thread Ian Lance Taylor
On Tue, Jun 21, 2016 at 12:42 PM, wrote: > Is `$ go test github.com/foo/proj/...` really supposed to work? Yes. > When I run it I get > > warning: "github.com/foo/proj/..." matched no packages > no packages to test > > But `cd src/github.com/foo/proj && go test ./...`

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

2016-06-21 Thread Alex Bligh
On 21 Jun 2016, at 19:55, 'Axel Wagner' via golang-nuts wrote: > The issue is, that a "KeyValuePair" (no matter if you implemented it > via generics or like you mention via interfaces) is a fundamentally useless > type and generics encourage people to add

[go-nuts] Getting a pointer in a type switch gives a *interface {} if case lists several options

2016-06-21 Thread raidopahtma
I have encountered some unexpected and inconsistent behavior with type switches. Can someone shed some light as to why Go behaves this way? Take a look at https://play.golang.org/p/YPV5YPtWF8 I would expect both of the switches to behave the same way, but for some reason the one with multiple

[go-nuts] Handling panics in go_kafka_client

2016-06-21 Thread chandradeepak . k
Hi, We are trying to build an application using the go_kafka_client, for managing the consumer creation etc. We find it very convenient and easy to use. Thanks for building! But in the go_kafka_client code we see a lot of panics. For example we created a consumer for a topic that doesn't

[go-nuts] Looking for go usage on QNX

2016-06-21 Thread esealman
Hello, Looking for using go on QNX OS. I can see that gc isn't supported on QNX, but I thought might work since Plan9, freeBSD etc are supported. Additional solution can be the gccGo, so appreciate any help recommendation on both approaches. Thanks, Efraim -- You received this message

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

2016-06-21 Thread 'Axel Wagner' via golang-nuts
The issue is, that a "KeyValuePair" (no matter if you implemented it via generics or like you mention via interfaces) is a fundamentally useless type and generics encourage people to add useless types. A "KeyValuePair" is a "struct { Key K, Value V }", plain and simple. It's not an

Re: [go-nuts] feature request: allow literal digit underscore grouping

2016-06-21 Thread Michael Jones
I asked for this a while back ("drop underscore between digits as in Ada") and the answer was no. I try to ask just once. This was shut down without much discussion at https://github.com/golang/go/issues/42. I agree that it's a nice feature. By the way, though, one nice aspect of Go is that

Re: [go-nuts] semantics of byteCount in gob encoding

2016-06-21 Thread Alex Flint
Oh I expected that since I only called encoder.Encode once, there would only be on repetition of the outermost segment. I was expecting the wireType to be within the inner "(-type id, encoding of a wireType)*" segment. Otherwise shouldn't the spec be ((byteCount, -type id, encoding of a

[go-nuts] feature request: allow literal digit underscore grouping

2016-06-21 Thread Roger Pack
I found recently when doing some language comparisons In a few other languages (ruby, java, etc.) underscores within numeric literals to make them more readable, ex: 10_000_000.times do ... end go ex: for i := 0; i < 1000; i++ { ... } I find it helps readability, and think it would be

[go-nuts] semantics of byteCount in gob encoding

2016-06-21 Thread Alex Flint
The gob docs state that a gob stream consists of (byteCount (-type id, encoding of a wireType)* (type id, encoding of a value))* I was expecting byteCount to be the number of bytes remaining in the entire packet, but that does not seem to be the case. For example when encoding a single

Re: [go-nuts] go get failing In Mac 10.11.4

2016-06-21 Thread Debraj Manna
Below is the ouput using the -x flag:- jabongs-MacBook-Pro-4:florest debraj$ go get -x ./... WORK=/var/folders/lp/3q9_2mn51hd9s4yj_jcf3jxmgp/T/go-build665863426 mkdir -p $WORK/github.com/jabong/floRest/src/examples/_obj/ mkdir -p $WORK/github.com/jabong/floRest/src/ cd

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

2016-06-21 Thread andrew . mezoni
>> What I mean is that most people who have followed the past generics discussions already know it's possible to implement them with efficient memory use and performance. So they don't need to worry much about that. Thank you for explanation. >> can they be implemented without making Go a

Re: [go-nuts] How to hide command line argument from ps

2016-06-21 Thread Matt Harden
It's generally a bad idea to try to improve security by hiding args. Much better to pass the argument another way, for instance via an open file descriptor that the program reads the value from. On Tue, Jun 21, 2016, 07:16 Hoping White wrote: > Hi, all > >I wonder is

Re: [go-nuts] How to hide command line argument from ps

2016-06-21 Thread Konstantin Khomoutov
On Tue, 21 Jun 2016 22:16:38 +0800 Hoping White wrote: > I wonder is there a way to hide command line arguments from > programs like “ps”? I can rewrite argv parameter for main in c > language, or use LD_PRELOAD to intercept libc_start_main, but all > these methods do not

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

2016-06-21 Thread Henry
You still haven't provided any argument why generics is indispensable. The reason why I am no longer sure about my position in this issue is because -while I agree that generics is useful- I don't think that generics is essential. In fact, all of C++ features are useful and implemented in a

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

2016-06-21 Thread Ian Davis
On Tue, Jun 21, 2016, at 03:17 PM, andrew.mez...@gmail.com wrote: > >>increase in cognitive load to decipher chains of type definitions. > > Sorry, but who are members of this mail lists? > This is a first time when I hear about such loads such as the > `cognitive load`. > Also I am possible

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

2016-06-21 Thread andrew . mezoni
>> increase in cognitive load to decipher chains of type definitions. Sorry, but who are members of this mail lists? This is a first time when I hear about such loads such as the `cognitive load`. Also I am possible here a single person who does not know anything about the `cognitive load to

[go-nuts] How to hide command line argument from ps

2016-06-21 Thread Hoping White
Hi, all I wonder is there a way to hide command line arguments from programs like “ps”? I can rewrite argv parameter for main in c language, or use LD_PRELOAD to intercept libc_start_main, but all these methods do not be functional in go. Thanks. -- You received this message because you

Re: [go-nuts] Unmarshalling and tags

2016-06-21 Thread Nate Finch
I'd like to see something like this: type Payment struct { ActionType paypal.ActionType `xml,yaml,json:"actionType,omitempty"` ReceiverList paypal.ReceiverList `xml,yaml,json:"actionType,omitempty"` } -- You received this message because you are subscribed to the Google Groups

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

2016-06-21 Thread Ian Davis
On Tue, Jun 21, 2016, at 01:45 PM, andrew.mez...@gmail.com wrote: > >>I am not saying that generics is bad, but I am questioning whether > >>generics is necessary. > > Please, do not panic. > If you worry about the following things: > - Generated code will grow when used generics > - Generated

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

2016-06-21 Thread andrew . mezoni
>> I am not saying that generics is bad, but I am questioning whether generics is necessary. Please, do not panic. If you worry about the following things: - Generated code will grow when used generics - Generated code will be more complex when used generics - Execution performance will slow

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

2016-06-21 Thread Micky
I guess that's for diplomatic reasons. If you watch talks of core contributors then I believe you'll know what I mean :) On Tue, Jun 21, 2016 at 5:15 AM, Rodrigo Kochenburger wrote: > Micky, I'm not sure where you're quoting from but they never said it's never > gonna happen. >

Re: [go-nuts] [ANN] primegen.go: Sieve of Atkin prime number generator

2016-06-21 Thread alb . donizetti
> Do you plan to include SSA for the x86 version as well? For an answer to this: yes, it seems like the plan is to port every supported architecture to SSA. It was discussed here: https://groups.google.com/d/msg/golang-dev/fSIl5Sbr4ek/10sgOsnDEAAJ Il giorno martedì 21 giugno 2016 03:39:41

[go-nuts] Treeless: distributed NoSQL key-value DB written in Go

2016-06-21 Thread David M.
Hi, I've just released Treeless (https://github.com/dv343/treeless), a new distributed NoSQL key-value DB written in Go. I have been focused on performance and simplicity and I think I have achieved good results. For example, Get performance is 20% slower compared to Redis, but Set

[go-nuts] Re: [?] emulating an opengl shader in cpu bound functions

2016-06-21 Thread Egon
On Tuesday, 21 June 2016 12:50:16 UTC+3, Egon wrote: > > > > On Monday, 20 June 2016 18:02:53 UTC+3, blue...@gmail.com wrote: >> >> >> >> >> I am attempting to generate

[go-nuts] go get failing In Mac 10.11.4

2016-06-21 Thread DM
Hi On Mac OS X 10.11.4 *go get* is failing with the below error. jabongs-MacBook-Pro-4:florest debraj$ go get ./... go install github.com/jabong/florest/src/common/config: open /var/folders/lp /3q9_2mn51hd9s4yj_jcf3jxmgp/T/go-build823644730/github.com/jabong/ florest/src/common/config.a: no

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

2016-06-21 Thread Henry
I am not saying that generics is bad, but I am questioning whether generics is necessary. On Tuesday, June 21, 2016 at 3:45:08 PM UTC+7, andrew...@gmail.com wrote: > >> I was one of the generics supporters for Go in this forum, but now I am > not so sure. > > But why? > Generic types is the

[go-nuts] Re: [?] emulating an opengl shader in cpu bound functions

2016-06-21 Thread Egon
On Monday, 20 June 2016 18:02:53 UTC+3, blue...@gmail.com wrote: > > > > > I am attempting to generate a random starfield, in go. This is something > that will need to

Re: [go-nuts] Send us your gophers!

2016-06-21 Thread Jan Mercl
On Sat, May 21, 2016 at 8:28 AM 'Andrew Gerrand' via golang-nuts < golang-nuts@googlegroups.com> wrote: > Renee French and I are doing a little secret project and would love it if you would draw a gopher and sent it to us. Hi Andrew, is / will be there be some public output of your little

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

2016-06-21 Thread andrew . mezoni
>> I was one of the generics supporters for Go in this forum, but now I am not so sure. But why? Generic types is the same types as and the regular types. Difference only in that the regular types does not have a parameters but generic types are always have at least one parameter. This is why

[go-nuts] Re: How to manage a web portal with multiple services without stopping and restarting everything at each release/fix?

2016-06-21 Thread Benjamin Measures
On Sunday, 19 June 2016 09:53:34 UTC+1, Simon Ritchie wrote: > > Whichever you choose, it will not be as good as PHP in some respects and I > predict that speed of redeployment will be one of them. > When deploying to hundreds of servers, deploying hundreds of files to each becomes

[go-nuts] Re: How to manage a web portal with multiple services without stopping and restarting everything at each release/fix?

2016-06-21 Thread Benjamin Measures
On Thursday, 16 June 2016 16:02:50 UTC+1, romano.p...@gmail.com wrote: > > In Layman terms, if I had a portal in php I could (of course it depends on > situations) simply replace the pages of the module for the Service 1 > without the need to stop everything (not only Service 2,3,4 and so on but

Re: [go-nuts] GoMobile window size always 800x800

2016-06-21 Thread Daniel Skinner
In my experience, designers aren't writing code or demoing experiences in native code. If they were, it wouldn't be that dissimilar to what I already see, either resizing a window or choosing a specific window size in chrome dev tools. Put bluntly, designers just aren't affected here and I think

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

2016-06-21 Thread Henry
I think we should carefully consider whether generics is worthy enough to be added into the language. It is easy to add a feature, but nearly impossible to remove one without breaking the backward compatibility promise. One thing for sure is that we are in the middle of a paradigm shift. I am

Re: [go-nuts] [?] emulating an opengl shader in cpu bound functions

2016-06-21 Thread Daniel Skinner
I pinned this question to my email b/c I'm going to be doing something similar soon and why not help a similar soul out, but really even though I can't give you a straight answer now, the answer is still pretty straight forward. There's nothing predominantly interesting between a gpu shader and a

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

2016-06-21 Thread andrew . mezoni
>> While later I realized that we still need some parameter check in the callee code to satisfy the interface matching (the generic version of each function in my proposal). A am sorry but your judgements is not correct. Here is a proofs: 1. It is redundant to perform check of the correctness

Re: [go-nuts] Unmarshalling and tags

2016-06-21 Thread Ain
teisipäev, 21. juuni 2016 9:47.54 UTC+3 kirjutas rog: > > I feel your pain - we quite often have tags with entries for three > formats (JSON, YAML and BSON) - but I'm not sure that collapsing them > is necessarily a good idea, as the named tags indicate that the object > is explicitly intended

Re: [go-nuts] Unmarshalling and tags

2016-06-21 Thread roger peppe
I feel your pain - we quite often have tags with entries for three formats (JSON, YAML and BSON) - but I'm not sure that collapsing them is necessarily a good idea, as the named tags indicate that the object is explicitly intended to be able to be marshaled with those formats. That said, it's

Re: [go-nuts] [?] emulating an opengl shader in cpu bound functions

2016-06-21 Thread Christian Mauduit
Hi, Using OpenGL to draw something that will end up on paper might prove somewhat complicated. As for "translating" a shader to something cpu bound, since a shader is more or less a program in some language that "has some remote parentness with C", you could probably do it. But the most pragmatic

[go-nuts] Re: Result is sometimes different despite using same value when encode by encoding/gob

2016-06-21 Thread Harry
Thank Dave and Jan. I understood completely. I'd consider another solution to manage that next. Thanks again. Harry. 2016年6月21日火曜日 14時58分39秒 UTC+9 Dave Cheney: > > To serialise the keys and values of a map and code would have to iterate > over it > > for k,v := range m { >// serialise

Re: [go-nuts] Result is sometimes different despite using same value when encode by encoding/gob

2016-06-21 Thread Jan Mercl
On Tue, Jun 21, 2016 at 7:44 AM Harry wrote: > Why serialized value is not invaliable when using map value. Map keys are comparable but they are not required to be ordered , ie. sorting them before serializing is not only