Re: [go-nuts] How to open browser with NTLM auth

2019-10-28 Thread shirokovea90
When I use go-ntlmssp I get error 401. Try use curl curl --ntlm -u: url, get 200 среда, 23 октября 2019 г., 9:11:23 UTC+3 пользователь Skip написал: > > Googling for "NTLM http go client", the first result looks legit: > > https://github.com/Azure/go-ntlmssp > > > On Tue, Oct 22, 2019 at 10:20

Re: [go-nuts] Need advice on AST formatting

2019-10-28 Thread Marvin Renich
* roger peppe [191028 04:49]: > On Sun, 27 Oct 2019, 02:52 Marvin Renich, wrote: > > I strongly encourage you to use > > > > var fset = token.NewFileSet() > > > > rather than > > > > fset := token.NewFileSet() > > > > Those two alternatives do exactly the same thing AFAIK. How is the latter

[go-nuts] Re: errors custom As

2019-10-28 Thread anderson . queiroz
The idea of As is to find an error in the wrapped errors, the error chain, which can be cast to the type you pass. I played a bit with them and made some examples: https://github.com/AndersonQ/go1_13_errors/blob/master/main.go#L103 Have a look in the implementation of As, it's nice and simple

Re: [go-nuts] Re: Slices, backing array, goroutines, perhaps Considerations for Go2

2019-10-28 Thread Wojciech S. Czarnecki
On Sun, 27 Oct 2019 20:20:07 + roger peppe wrote: > If two things aren't writing concurrently to the same address, what's the > problem? I've got an impression that OP is concerned about arriving at inconsistent/"impossible" shared state (due to poorly thought architecture). 30-20yrs ago

Re: [go-nuts] Re: Slices, backing array, goroutines, perhaps Considerations for Go2

2019-10-28 Thread Dan Kortschak
You are absolutely right. Apologies. On Mon, 2019-10-28 at 08:43 +, roger peppe wrote: > On Sun, 27 Oct 2019, 21:31 Dan Kortschak, wrote: > > > This is not necessarily due to races. You can have this exact > > situation > > occurring in single threaded code. I don't think any mention of >

Re: [go-nuts] Re: Slices, backing array, goroutines, perhaps Considerations for Go2

2019-10-28 Thread atd...@gmail.com
Yes, the issue is twofold. Because everything is passed by "copy", it might feel safe to pass around structs with slice fields, especially and perhaps unknowingly as "interior fat pointers" in structs. But, one should remember that these objects are always shallow copies in the sense that

Re: [go-nuts] Need advice on AST formatting

2019-10-28 Thread roger peppe
On Sun, 27 Oct 2019, 02:52 Marvin Renich, wrote: > * Denis Cheremisov [191026 06:09]: > > The answer was simple: > > > > var fset token.FileSet – wrong > > > > fset := token.NewFileSet() – right > > I believe I am in the minority here, but I am not a singleton minority. > There are at least

Re: [go-nuts] Re: Slices, backing array, goroutines, perhaps Considerations for Go2

2019-10-28 Thread roger peppe
On Sun, 27 Oct 2019, 21:31 Dan Kortschak, wrote: > This is not necessarily due to races. You can have this exact situation > occurring in single threaded code. I don't think any mention of race > issues was made here. > The thread subject mentions goroutines and the original message talks

Re: [go-nuts] Need advice on AST formatting

2019-10-28 Thread Michel Levieux
Oh, well I'm glad it solved the problem for you Denis! Unfortunately, it seems mine's somewhere else since I was already using token.NewFileSet()... I think I might have to "re-handle" the spacing logic within my AST since I'm changing many many things and it's possible that I just break the