[go-nuts] Re: Previewing Go Docs with Modules

2018-12-22 Thread Karel Minařík
On Friday, December 21, 2018 at 10:44:36 PM UTC+1, matthew...@gmail.com wrote: > > (...) Does anyone know of a way that I can do this, or if I can get > godoc to let me view my packages that are module aware? > The solution I came up with is to have a bash script like this in my Makefile: mkdi

Re: [go-nuts] if/switch statements as expressions

2018-12-22 Thread 'Axel Wagner' via golang-nuts
On Sat, Dec 22, 2018 at 8:05 PM Viktor Kojouharov wrote: > Curiously, Java 12 will also support switch expressions, and java is about > as non-expressive as it gets. > What makes you say that? Java is as much of an expression language as C. In particular, assignments are expressions, which I thi

Re: [go-nuts] if/switch statements as expressions

2018-12-22 Thread Sameer Ajmani
Inline functions can meet this need, though there's usually a better way: v := func() T { if b { return v1 } return v2 }() On Sat, Dec 22, 2018 at 2:05 PM Viktor Kojouharov wrote: > I've used kotlin extensively, where ifs and switches are expressions. I've > also seen rust support them. Curiously

Re: [go-nuts] if/switch statements as expressions

2018-12-22 Thread Viktor Kojouharov
I've used kotlin extensively, where ifs and switches are expressions. I've also seen rust support them. Curiously, Java 12 will also support switch expressions, and java is about as non-expressive as it gets. On Wednesday, December 19, 2018 at 11:39:32 PM UTC+2, Tyler Compton wrote: > > There is

[go-nuts] Re: Best practices for using methods on types to write SQL

2018-12-22 Thread Victor Giordano
Hi Nick!. Allow to me provide you with some insights about working with a sql DBMS as persistence layer for an app. - *Json.Marshal/Unmarshal functions works like a charm* with columns of type JSON. As you state once you have a table with one column of then you can store anything on in