Re: [go-nuts] vim setup for auto go fmt on save.

2016-10-10 Thread 김용빈
Tank you Sander. I successfully installed and it works well. Still I want to know simple way though. If anyone knows about it, please let me know. :) -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop

[go-nuts] big.Rat anomalies

2016-10-10 Thread Dave Cohen
I'm getting an unexpected result of big.Rat.Quo(). In trying to track it down, I ran into an unexpected result from big.Rat.SetFloat64(). So I have a few questions... Code snippet below reproduces what I see in my application, and is also in https://play.golang.org/p/Eph67_1yd- I'm working

Re: [go-nuts] spec:

2016-10-10 Thread T L
Thanks for the explanation. On Tuesday, October 11, 2016 at 12:55:06 AM UTC+8, Ian Lance Taylor wrote: > > On Mon, Oct 10, 2016 at 9:51 AM, T L > wrote: > > > > On Tuesday, October 11, 2016 at 12:19:10 AM UTC+8, Ian Lance Taylor > wrote: > >> > >> On Mon, Oct 10, 2016

Re: [go-nuts] spec:

2016-10-10 Thread T L
On Tuesday, October 11, 2016 at 12:21:01 AM UTC+8, Jan Mercl wrote: > > On Mon, Oct 10, 2016 at 6:01 PM Paul Borman > wrote: > > > In your representation, P means "identifiers are different", so the > resulting false means the identifiers are the same, which is what the OP

Re: [go-nuts] vim setup for auto go fmt on save.

2016-10-10 Thread Tarsis Azevedo
Fatih, vim-go author, wrote awesome tutorial about that. https://github.com/fatih/vim-go-tutorial/blob/master/README.md Tarsis Figueredo Azevedo. --- Celular: (21) 998524668 @tarsisazevedo --- On Mon, Oct 10, 2016 at 10:24 AM,

Re: [go-nuts] spec:

2016-10-10 Thread Ian Lance Taylor
On Mon, Oct 10, 2016 at 9:51 AM, T L wrote: > > On Tuesday, October 11, 2016 at 12:19:10 AM UTC+8, Ian Lance Taylor wrote: >> >> On Mon, Oct 10, 2016 at 8:39 AM, T L wrote: >> > In the section of go spec: >> >

Re: [go-nuts] spec:

2016-10-10 Thread Jan Mercl
On Mon, Oct 10, 2016 at 6:29 PM T L wrote: > So, two non-exported identifiers spelled same but in different packages are the same identifiers? See Ian's answer. Note also the specs's preceding sentence: "Given a set of identifiers." -- -j -- You received this message

Re: [go-nuts] spec:

2016-10-10 Thread T L
On Tuesday, October 11, 2016 at 12:19:10 AM UTC+8, Ian Lance Taylor wrote: > > On Mon, Oct 10, 2016 at 8:39 AM, T L > wrote: > > In the section of go spec: > > https://golang.org/ref/spec#Uniqueness_of_identifiers, it says: > > > > Two identifiers are different if they

Re: [go-nuts] big.Rat anomalies

2016-10-10 Thread Michael Jones
Dave, try this version: https://play.golang.org/p/p5zyQF1Sdr From: on behalf of Jan Mercl <0xj...@gmail.com> Date: Monday, October 10, 2016 at 4:40 PM To: Dave Cohen , golang-nuts Subject: Re: [go-nuts]

Re: [go-nuts] go install with -installsuffix fails on linux but not mac?

2016-10-10 Thread Ian Rose
(sorry if I already sent this - groups UI being weird) Hmm... I seem to get the same results on both machines: Mac: $ go list -f '{{.Name}} {{.Stale}}' std | grep true | head $ go list -installsuffix nocgo -f '{{.Name}} {{.Stale}}' std | grep true | head tar true zip true bzip2 true lzw true

[go-nuts] lxn/walk goroutine blocks

2016-10-10 Thread rbirac
Hi Guys, I’m building a GUI for my robot. I’m using Windows, so found lxn/walk. Working from the examples, I built a GUI which did all that I want right now. I developed it in the main() function, just like the examples; but for the actual robot, I want it to run in its own goroutine with

Re: [go-nuts] what's the difference between Golang and Java about interface?

2016-10-10 Thread Haddock
Am Samstag, 8. Oktober 2016 17:31:27 UTC+2 schrieb Pietro Gagliardi (andlabs): > > In Java, if an interface contains exactly one method, and that method is > not already part of java.lang.Object, the syntax > > Interface i = (arguments) -> { > code > }; > > will make an object i of that

[go-nuts] go install with -installsuffix fails on linux but not mac?

2016-10-10 Thread Ian Rose
On my macbook pro, I'm able to `go install` with a custom installsuffix just fine: $ ls -l /usr/local/go/pkg/ total 0 drwxr-xr-x 5 root wheel 170 Feb 25 2016 bootstrap drwxr-xr-x 58 root wheel 1972 Feb 25 2016 darwin_amd64 drwxr-xr-x 57 root wheel 1938 Sep 8 2015

[go-nuts] SQLBoiler Screencast - Getting Started

2016-10-10 Thread Patrick O'Brien
We've made a screen cast highlighting how to get started using the SQLBoiler ORM generator. Please let us know what you think: https://www.youtube.com/watch?v=fKmRemtmi0Y -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from

Re: [go-nuts] go install with -installsuffix fails on linux but not mac?

2016-10-10 Thread Ian Lance Taylor
On Mon, Oct 10, 2016 at 12:48 PM, Ian Rose wrote: > On my macbook pro, I'm able to `go install` with a custom installsuffix just > fine: > > > $ ls -l /usr/local/go/pkg/ > total 0 > drwxr-xr-x 5 root wheel 170 Feb 25 2016 bootstrap > drwxr-xr-x 58 root wheel 1972 Feb

[go-nuts] Code Review for TLS Proxies

2016-10-10 Thread 'Anmol Sethi' via golang-nuts
My school uses DPI (deep packet inspection) to block protocols like SSH and OpenVPN. Additionally, few remote ports are enabled. Sometimes I want to login to my VPS from school to fix or work on something, but I cannot because SSH is blocked. Furthermore, my school has a approved (yes, approved by

[go-nuts] time representation to use with javascript

2016-10-10 Thread bsr
Hello, I store all time values in UTC, and since it runs on google app engine, the precision might be in microseconds. https://github.com/golang/appengine/blob/master/datastore/save.go#L21 I want to display this time in client side with moment.js. But, javascript doesn't support int64, so how

Re: [go-nuts] Turning off nagle's algorithm for http.Client

2016-10-10 Thread hay
I stand corrected, it is there in "newTCPConn" function. On Monday, October 10, 2016 at 10:16:27 AM UTC+4, Sokolov Yura wrote: > > Read carefully, and you will not need to do redundant work and write > redundant code. > > It is really here: >

Re: [go-nuts] spec:

2016-10-10 Thread 'Paul Borman' via golang-nuts
In your representation, P means "identifiers are different", so the resulting false means the identifiers are the same, which is what the OP asked. On Mon, Oct 10, 2016 at 8:47 AM, Jan Mercl <0xj...@gmail.com> wrote: > > On Mon, Oct 10, 2016 at 5:39 PM T L wrote: > > > Two

Re: [go-nuts] spec:

2016-10-10 Thread Ian Lance Taylor
On Mon, Oct 10, 2016 at 8:39 AM, T L wrote: > In the section of go spec: > https://golang.org/ref/spec#Uniqueness_of_identifiers, it says: > > Two identifiers are different if they are spelled differently, or if they > appear in different packages and are not exported.

Re: [go-nuts] spec:

2016-10-10 Thread Jan Mercl
On Mon, Oct 10, 2016 at 6:01 PM Paul Borman wrote: > In your representation, P means "identifiers are different", so the resulting false means the identifiers are the same, which is what the OP asked. I put it simple but I still managed to misread my own simple code correctly

Re: [go-nuts] [ANN] Gleam - A Go-based MapReduce system with Luajit, Unix Pipes

2016-10-10 Thread Chris Lu
Thanks for the question! It's nice that you know glow. Gleam is very similar to glow, but has a very different approach after some rethinking. Glow is based on channels and reflection, which are less performant. There is a performance comparison example:

Re: [go-nuts] Turning off nagle's algorithm for http.Client

2016-10-10 Thread Sokolov Yura
Read carefully, and you will not need to do redundant work and write redundant code. It is really here: https://github.com/golang/go/blob/release-branch.go1.6/src/net/tcpsock_posix.go If you don't see it... Then you reading skill is weak. -- You received this message because you are

[go-nuts] vim setup for auto go fmt on save.

2016-10-10 Thread 김용빈
Hello, How could I achieve auto go fmt on save in vim? (with 2~3 lines of code) I don't want install entire plug-in like vim-go. Or is it better to do? Thank you. -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this

Re: [go-nuts] vim setup for auto go fmt on save.

2016-10-10 Thread Sander van Harmelen
If you want to develop Go in vim, I would strongly suggest to just install and use the vim-go package/plugin. It will help you with a lot of stuff, but most can be turned of if you don’t want of need it. Sander On 10 Oct 2016, at 08:15: 49, 김용빈 wrote: Hello, How could I

Re: [go-nuts] Re: Can not install "go-lang-idea-plugin" onto IntelliJ IDEA

2016-10-10 Thread Florin Pățan
I'm happy to hear that it worked out. If you have any issues, feel free to ping me. I'm also on Gophers Slack or on the Gitter support channel. Enjoy using the plugin. On Mon, 10 Oct 2016, 04:15 Yuuki T, wrote: > The my download problem had been gone. > > I was able

Re: [go-nuts] Re: [ANN] gorram: like go run for any* function in stdlib or GOPATH

2016-10-10 Thread Mathieu Lonjaret
Looks shiny! But is there some sort of cache I have to clear? I've just updated and rebuilt, and I still get the old behaviour. On 8 October 2016 at 04:05, Nate Finch wrote: > ...and now it works like you'd hope :) > > > $ gorram net/http Get https://npf.io/gorram/run >

[go-nuts] Re: what's the difference between Golang and Java about interface?

2016-10-10 Thread gottadoit
An interesting aside about Java Interfaces that most people don't know is that you can have an empty Interface without methods or members and then declare different objects as implementing that empty interface. The purpose of this in Java is different then in Golang but it allows arbitrary

Re: [go-nuts] Re: what's the difference between Golang and Java about interface?

2016-10-10 Thread Henrik Johansson
Yet a notable such marker interface Serializable is known by almost all Java developers ;) On Tue, Oct 11, 2016, 02:04 wrote: > An interesting aside about Java Interfaces that most people don't know is > that you can have an empty Interface without methods or members and

[go-nuts] Marshal XML Mixed Content

2016-10-10 Thread Scott
I'm trying to Marshal XML where an element has mixed content: https://www.w3.org/TR/REC-xml/#sec-mixed-content I tried just using []interface{} but if I put in just a string, Marshal surrounds each string with the name of the slice: https://play.golang.org/p/erh3mQmrZD I'm trying to get the

[go-nuts] Re: time representation to use with javascript

2016-10-10 Thread bsr
Just saw that time implements MarshalJSON, so may be string output may be better. https://golang.org/src/time/time.go?s=26891:26934#L918 On Monday, October 10, 2016 at 11:22:48 PM UTC-4, bsr wrote: > > Hello, > > I store all time values in UTC, and since it runs on google app engine, > the

Re: [go-nuts] big.Rat anomalies

2016-10-10 Thread Jan Mercl
On Mon, Oct 10, 2016 at 4:29 PM Dave Cohen wrote: > numerator.SetFloat64(118.5285714285714) // becomes 118.528571428571396495499357115477 > big.NewRat(592642857142857, 5) // becomes 118.52857142857140 - more accurate than SetFloat64 above! > >

[go-nuts] spec:

2016-10-10 Thread T L
In the section of go spec: https://golang.org/ref/spec#Uniqueness_of_identifiers, it says: Two identifiers are different if they are spelled differently, or if they appear in different packages and are not exported

Re: [go-nuts] spec:

2016-10-10 Thread Jan Mercl
On Mon, Oct 10, 2016 at 5:39 PM T L wrote: > Two identifiers are different if they are spelled differently, or if they appear in different packages and are not exported . Otherwise, they