Re: [go-nuts] Go 2 generics counterproposal: giving up restricting types

2019-05-31 Thread Nick Keets
On Thu, May 30, 2019 at 9:26 PM Ian Lance Taylor wrote: > One of my guidelines for an acceptable generics proposal is that > people can write Min and Max. Your proposal admits that it doesn't > permit that. I think that is a problem. I'm fine with the general > idea of "do 80% of the job" but

Re: [go-nuts] Go 2 generics counterproposal: giving up restricting types

2019-05-31 Thread fgergo
On 5/31/19, Nick Keets wrote: ... > This proposal is very interesting and seems to fit nicely into Go, with > minimal disruption. And speaking personally, it would cover 99% of my needs > for generics (I'm not that interested in Min/Max, but writing functions to > get map keys gets old fast). Inte

[go-nuts] Go package manager

2019-05-31 Thread yashish . dua
Hi everyone! I recently build an interesting Go tool - GPM (Go Project Manager). It allows you to build and manage go projects. Ont op, it also allows to update version of Go from cli. Check it out: https://github.com/YashishDua/gpm Feedback is appreciated! -- You received this message becaus

Re: [go-nuts] Go 2 generics counterproposal: giving up restricting types

2019-05-31 Thread Michal Strba
@Ian, I have been thinking and I’ve come up with a possible solution to yours and some other problems. I’d love to hear your thoughts on it. Note, that this is a very fresh idea. I’m addressing two problems here: 1. Inability to do Min/Max and other generic numeric functions. 2. The

Re: [go-nuts] Go 2 generics counterproposal: giving up restricting types

2019-05-31 Thread Robert Johnstone
Hello, I'm not sure that Min and Max need to be in the 80%. It's annoying to write them repeatedly, but they are also very short. The place where I typically miss generics is larger chunks of code, such as concurrency patterns. I'm certain others are looking at datatypes. Why do Min and Max

[go-nuts] Re: Go Module Mirror and Checksum Database in Beta!

2019-05-31 Thread wilk
On 30-05-2019, Katie Hockman wrote: > The module mirror at proxy.golang.org serves the go command=E2=80=99s proxy > protocol. The Go 1.13 development tree uses this mirror for all module > downloads by default. See the go command documentation at tip >

Re: [go-nuts] Go 2 generics counterproposal: giving up restricting types

2019-05-31 Thread David Riley
Because Min and Max are very good and simple indicators of whether the mechanism is generic enough to handle a fairly common idiom: small functions for similarly behaved items, say comparable items, which are annoying and repetitive to write for every data type which might support the operation

[go-nuts] Re: Go Module Mirror and Checksum Database in Beta!

2019-05-31 Thread Amnon Baron Cohen
See https://go.googlesource.com/proposal/+/master/design/25530-sumdb.md The current behavior is not ideal from a security point of view. So it is good that 1.13 is fixing this. And unless the fix is default, most users will not get the benefit. Anyone who wants to old behavior just needs to set t

Re: [go-nuts] Go 2 generics counterproposal: giving up restricting types

2019-05-31 Thread Robert Engels
Is that really true though? You can have one package that defines min/max for the built-in types (because it uses operators), and then one that uses method(s) Less() and Equals() that works with generics. A similar technique can be used in sorting. -Original Message- >From: David Ri

Re: [go-nuts] Announcing NSWrap -- a comprehensive Objective-C binding generator for MacOS

2019-05-31 Thread Robert Engels
Isn't a lack of ARC support a critical limitation, as ARC is required going forward, and many of the newer API's assume ARC behind the scenes?-Original Message- From: Greg Pomerantz Sent: May 30, 2019 8:25 AM To: golang-nuts Subject: [go-nuts] Announcing NSWrap -- a comprehensive Objectiv

Re: [go-nuts] Announcing NSWrap -- a comprehensive Objective-C binding generator for MacOS

2019-05-31 Thread Greg Pomerantz
ARC support should be doable, it would mean at least i) using bridging casts instead of void* for every Objective-C object, and ii) disabling retain, release and autorelease methods, and disallow NSAutoreleasePool class. On Friday, May 31, 2019 at 11:51:01 AM UTC-4, Robert Engels wrote: > > Isn

Re: [go-nuts] Announcing NSWrap -- a comprehensive Objective-C binding generator for MacOS

2019-05-31 Thread Greg Pomerantz
Also I don't think an API is going to assume or require ARC -- as far as I understand it, ARC is just a compiler shortcut that adds retain and release calls so the programmer doesn't have to, it is not any sort of runtime memory management or garbage collection system. As long as Clang has a -f

[go-nuts] Re: Go Module Mirror and Checksum Database in Beta!

2019-05-31 Thread wilk
On 31-05-2019, Amnon Baron Cohen wrote: > --=_Part_967_922323128.1559316498912 > Content-Type: multipart/alternative; > boundary="=_Part_968_1050003518.1559316498912" > > --=_Part_968_1050003518.1559316498912 > Content-Type: text/plain; charset="UTF-8" > Content-Transfer-Encoding

Re: [go-nuts] Re: Interesting public commentary on Go...

2019-05-31 Thread Devon H. O'Dell
Maybe this story about suggesting the murder of a colleague is supposed to be a tongue-in-cheek joke, but I want to push back heavily against it. And I’m sorry that this is devolving significantly from the original topic, but I don’t think this should slide by. Though my professional experience is

Re: [go-nuts] Go 2 generics counterproposal: giving up restricting types

2019-05-31 Thread Michal Strba
Btw, as is demonstrated in the proposal, sorting can be solved by passing a comparator to the function: ```go func Sort(a []gen T, less func(T, T) bool) ``` This is actually a far more flexible way than sorting based on an operator or a `Less` method. Sorting based on an operator or `Less` limits

Re: [go-nuts] Announcing NSWrap -- a comprehensive Objective-C binding generator for MacOS

2019-05-31 Thread Michael Jones
This is impressive. Thank you. On Fri, May 31, 2019 at 9:33 AM Greg Pomerantz wrote: > Also I don't think an API is going to assume or require ARC -- as far as I > understand it, ARC is just a compiler shortcut that adds retain and release > calls so the programmer doesn't have to, it is not any

Re: [go-nuts] Go Module Mirror and Checksum Database in Beta!

2019-05-31 Thread Jim Ancona
On Thu, May 30, 2019 at 5:14 PM Katie Hockman wrote: > Our privacy policy explains how we collect and use your information. The > privacy policy for all of these services is proxy.golang.org/privacy. > I tried visiting that page, which redirected to https://policies.google.com/privacy Unfortunat

[go-nuts] 【Go Specification fix proposal】about ConstSpec = IdentifierList [ [ Type ] "=" ExpressionList ] .

2019-05-31 Thread k . kubo . private . mobile
In Go Language Specification, I saw the definition of const. https://golang.org/ref/spec#Constant_declarations ConstDecl = "const" ( ConstSpec | "(" { ConstSpec ";" } ")" ) .ConstSpec = IdentifierList

Re: [go-nuts] 【Go Specification fix proposal】about ConstSpec = IdentifierList [ [ Type ] "=" ExpressionList ] .

2019-05-31 Thread Jan Mercl
On Fri, May 31, 2019 at 9:52 PM wrote: > because const declaration cannot omit value. https://play.golang.org/p/gLlHpdpniTg -- 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

Re: [go-nuts] Go Module Mirror and Checksum Database in Beta!

2019-05-31 Thread Katie Hockman
Thanks for the feedback! There is an issue tracking this here: https://github.com/golang/go/issues/32343 On Fri, May 31, 2019, 3:17 PM Jim Ancona wrote: > > > On Thu, May 30, 2019 at 5:14 PM Katie Hockman wrote: > >> Our privacy policy explains how we collect and use your information. The >> pr

[go-nuts] Re: Go Module Mirror and Checksum Database in Beta!

2019-05-31 Thread Amnon Baron Cohen
Not really. You need the list feature of GOPROXY, which is only available in 1.13 (or tip). > > Is there a way to test proxy.golang.org with go1.12 if we have private > dependencies ? > > -- > William Dodé > > -- You received this message because you are subscribed to the Google Groups "

Re: [go-nuts] Go 2 generics counterproposal: giving up restricting types

2019-05-31 Thread Randall O'Reilly
This seems similar to previous proposals based on introducing kind-based type categories for contracts. Putting the kind right there in the arg instead of a separate contract seems like an improvement, keeping it more local to where it is used. Why not just take this one step further and just

[go-nuts] Re: Go package manager

2019-05-31 Thread Justin Israel
On Saturday, June 1, 2019 at 12:43:50 AM UTC+12, yashi...@gmail.com wrote: > Hi everyone! > > I recently build an interesting Go tool - GPM (Go Project Manager). It allows > you to build and manage go projects. Ont op, it also allows to update version > of Go from cli. > Check it out: https://gi

[go-nuts] go version go1.12 and cannot find module providing package

2019-05-31 Thread 'Bryan Mills' via golang-nuts
The highest release tag on that module is v0.0.2, and that version indeed does not provide the clis package. If you want a commit that is more recent than the latest release, you need to request that commit to 'go get' explicitly. -- You received this message because you are subscribed to the

Re: [go-nuts] Announcing NSWrap -- a comprehensive Objective-C binding generator for MacOS

2019-05-31 Thread robert engels
What I meant was that the refs should be treated like any Go object instance, and when collected on the Go side it should dec the ref count so the object can be freed on the OSX side. Might be tricky with weak refs, etc. Is that what happens? > On May 31, 2019, at 11:33 AM, Greg Pomerantz wro

Re: [go-nuts] Announcing NSWrap -- a comprehensive Objective-C binding generator for MacOS

2019-05-31 Thread Greg Pomerantz
I see. No, that is not how it works, the user needs to manually handle memory management for all Objective-C objects, calling Release() on objects that are manually allocated and no longer used, and calling Retain() to take ownership of objects that need to be kept. In many contexts (e.g. NSApp

[go-nuts] Go 1.8 port to FreeBSD/PowerPC64

2019-05-31 Thread Curtis Hamilton
I’m porting Go 1.8 to FreeBSD/PowerPC64. I’ve successfully built go-FreeBSD-ppc64-bootstrap using go on FreeBSD/amd64. However, l’m getting the error go: cannot find GOROOT directory, when executing ‘go env’ on the target system. I’m not sure if this is a code issue. I’ve tried some of the ti

[go-nuts] Is there a compiler options to detect and disable unsafe uses in third-party packages?

2019-05-31 Thread T L
. -- 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. To view this discussion on the web visit https://groups.google.com/d/