Re: [go-nuts] What 5 things does Go need in 2017?

2016-09-11 Thread Ian Lance Taylor
On Sun, Sep 11, 2016 at 6:44 PM, Mark Richman wrote: > > I would definitely be interested in triage, backlog refinement, etc. Are > there product owners designated for each functional area? I could start by > making sure new issues are at least assigned to the correct PO

[go-nuts] Two Related Questions. (1) Map Concurrency (2) Making Multidimensional Arrays

2016-09-11 Thread davidmiller124
*I have two Golang questions that I hope someone could help me out with.* *1) Am I misunderstanding Golang maps?* *I'm trying to translate a project from PHP to Golang for the websockets and the concurrency. * *However, I can't do this.* * var MyArray [string]string*

Re: [go-nuts] What 5 things does Go need in 2017?

2016-09-11 Thread Mark Richman
Ian, I would definitely be interested in triage, backlog refinement, etc. Are there product owners designated for each functional area? I could start by making sure new issues are at least assigned to the correct PO for prioritization. With respect to packaging, I'm aware of the current

Re: [go-nuts] Re: Why a single go routine with sleep is using 100% cpu (1 core)

2016-09-11 Thread Ilya Kostarev
On 09/12/2016 03:01 AM, Sagar P. wrote: Ah, I see my mistake. Removed default to avoid a busy-loop. Thanks! Without `default` you need hot `for` and `select` at all. Just _ = <-channel: fmt.Println("Go routine has ended") os.Exit(0) would be enough. In real situations however

Re: [go-nuts] What 5 things does Go need in 2017?

2016-09-11 Thread aroman
There's also decimal128 support (first via a third-party library before inclusion into the language itself): https://github.com/golang/go/issues/12332 =) - Augusto On Sunday, September 11, 2016 at 5:01:21 PM UTC-7, Pablo Rozas-Larraondo wrote: > > Hi Mark, > > I can also suggest you to look

[go-nuts] Re: Why a single go routine with sleep is using 100% cpu (1 core)

2016-09-11 Thread Sagar P.
Ah, I see my mistake. Removed default to avoid a busy-loop. Thanks! On Sunday, September 11, 2016 at 4:11:26 PM UTC-7, Sagar P. wrote: > > go version > go version go1.6.3 linux/amd64 > > uname -r > 3.13.0-95-generic > > Below code is using 100% cpu (1 full core) > > package main > > import ( >

Re: [go-nuts] Nil interface/pointer

2016-09-11 Thread Dan Kortschak
On Sun, 2016-09-11 at 19:41 +1000, Kiki Sugiaman wrote: > Not exactly a solution for the faint hearted, hah! It's long, but not complicated, and in the context of Axel's comment would be placed in a helper of some variety. For those at home, it's necessary to take the address of the interface

[go-nuts] Re: [ANN] A terminal based search engine for bash commands, built with Go

2016-09-11 Thread johnny-john
Hey, thanks for the feedback, and code review :)) The swap files, I am definitely removing. Printing without no limit is definitely a feature I want to get done! Sorting is a very good idea, I think it will be done on the server side though. That cookbook is epic, thanks for the heads up! The

Re: [go-nuts] Another divide by zero (float) question

2016-09-11 Thread Ian Lance Taylor
On Sun, Sep 11, 2016 at 11:40 AM, wrote: > https://play.golang.org/p/tLSyUw1Ojq > > This operation is caught by the compiler > > a:=float32(1) / float32(0) > > > ok This has been asked before - but not with a satisfactory answer afaict > > The spec says (

[go-nuts] Another divide by zero (float) question

2016-09-11 Thread xiiophen
https://play.golang.org/p/tLSyUw1Ojq This operation is caught by the compiler a:=float32(1) / float32(0) ok This has been asked before - but not with a satisfactory answer afaict The spec says ( https://golang.org/ref/spec#Arithmetic_operators ) *The result of a floating-point or complex

Re: [go-nuts] What 5 things does Go need in 2017?

2016-09-11 Thread Ian Lance Taylor
On Sun, Sep 11, 2016 at 6:43 AM, Mark Richman wrote: > > I'm somewhat new to the community, and seek to understand its challenges > better. I'm also looking for opportunities to contribute. > > To that end, what 5 things does Go need in 2017? > > For example: language

[go-nuts] [ANN] A terminal based search engine for bash commands, built with Go

2016-09-11 Thread johnny-john
Hi all! Just thought about dropping this link here, the codebase is VERY small, so if you are a newbie looking for a project to get into, have a look: https://github.com/crufter/borg Cheers -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To

Re: [go-nuts] how to resolve the warning about composite literal uses unkeyed fields .

2016-09-11 Thread gaojingan
Thank you very much 在 2016年8月24日星期三 UTC+8下午2:07:52,Deshi Xiao写道: > > Thanks Matt > > 2016-08-23 9:56 GMT+08:00 Matt Harden : > >> cluster.ImageFilterOptions has an embedded field of type >> types.ImageListOptions. When fields are embedded, the field name is set to >> the

Re: [go-nuts] Re: Can't understand untyped constant behavior

2016-09-11 Thread Manlio Perillo
Il giorno domenica 11 settembre 2016 13:30:40 UTC+2, Uvelichitel ha scritto: > > > On 09/10/2016 09:18 PM, Manlio Perillo wrote: > > Il giorno giovedì 8 settembre 2016 17:31:55 UTC+2, Uvelichitel ha scritto: >> >> >> func main() { >> const x, y = 5, 3 >> var f float32 = x

[go-nuts] Re: Assigning +Inf to a float32 ..

2016-09-11 Thread xiiophen
ok thanks - that seems to be them all I think the library would benefit from more 'obvious' , built in constant, or single parameterless function to generate these - more commonly as values to test output against, rather than inputs. I'll put in that request and see if it gets picked up. Also

Re: [go-nuts] Re: Can't understand untyped constant behavior

2016-09-11 Thread Ian Lance Taylor
On Sun, Sep 11, 2016 at 4:33 AM, Ilya Kostarev wrote: > > On 09/10/2016 09:18 PM, Manlio Perillo wrote: > > Il giorno giovedì 8 settembre 2016 17:31:55 UTC+2, Uvelichitel ha scritto: >> >> >> func main() { >> const x, y = 5, 3 >> var f float32 = x / y

Re: [go-nuts] Re: Can't understand untyped constant behavior

2016-09-11 Thread Ilya Kostarev
On 09/10/2016 09:18 PM, Manlio Perillo wrote: Il giorno giovedì 8 settembre 2016 17:31:55 UTC+2, Uvelichitel ha scritto: func main() { const x, y = 5, 3 var f float32 = x / y fmt.Println(f) } In your case the default type of x and y

Re: [go-nuts] Nil interface/pointer

2016-09-11 Thread Kiki Sugiaman
Thanks, Dan. Not exactly a solution for the faint hearted, hah! -- 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-nuts+unsubscr...@googlegroups.com. For

RE: [go-nuts] Assigning +Inf to a float32 ..

2016-09-11 Thread John Souvestre
Ignore. math.NaN() is there! J John John Souvestre - New Orleans LA From: John Souvestre [mailto:j...@souvestre.com] Sent: 2016 September 11, Sun 02:39 To: 'golang-nuts' Subject: RE: [go-nuts] Assigning +Inf to a float32 .. This does beg the question: Why is there no

RE: [go-nuts] Assigning +Inf to a float32 ..

2016-09-11 Thread John Souvestre
This does beg the question: Why is there no math.NaN() function? John John Souvestre - New Orleans LA From: golang-nuts@googlegroups.com [mailto:golang-nuts@googlegroups.com] On Behalf Of Dave Cheney Sent: 2016 September 11, Sun 01:00 To: golang-nuts Cc: xiiop...@gmail.com Subject:

Re: [go-nuts] Assigning +Inf to a float32 ..

2016-09-11 Thread Dave Cheney
https://play.golang.org/p/RthMnILvkP func main() { inf := float32(math.Inf(+1)) fmt.Println(inf) } On Sunday, 11 September 2016 15:58:04 UTC+10, bradfitz wrote: > > Not beautiful, but... > > https://play.golang.org/p/WWEEJN8LcF > > func main() { > i32 := math.Float32frombits(0x7F80) >