Re: [go-nuts] Sum type experiment

2020-08-11 Thread Sina Siadat
Thanks for the link, Ian. I will have a look at it :) -- 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

[go-nuts] Sum type experiment

2020-08-11 Thread Sina Siadat
Hi golang-dev :) I was wondering what would be an idiomatic Go way to implement a basic sum type in Go. After several iterations I came up with 2 approaches I will share here. (1) Group types in an interface The first approach does not require any new tools and is statically checked by Go1

Re: [go-nuts] [ANN] A gradient boosting regressor package

2018-02-06 Thread Sina Siadat
Thanks for the link! On Mon, Feb 5, 2018 at 4:22 PM Aliaksandr Valialkin <valy...@gmail.com> wrote: > > > On Tuesday, January 30, 2018 at 12:43:38 AM UTC+2, Sina Siadat wrote: >> >> Hi Sebastien, >> >> ​Thanks for your comment and question :) >> >

Re: [go-nuts] [ANN] A gradient boosting regressor package

2018-01-29 Thread Sina Siadat
u intend to add an open source license? If not, be sure to read the GitHub default license. > > Matt > > On Monday, January 29, 2018 at 4:43:38 PM UTC-6, Sina Siadat wrote: >> >> Hi Sebastien, >> >> Thanks for your comment and question :) >> >

Re: [go-nuts] [ANN] A gradient boosting regressor package

2018-01-29 Thread Sina Siadat
Hi Sebastien, ​Thanks for your comment and question :) > I have one "drive-by-comment" and a question: > you could have perhaps used gonum for the stats stuff :) ​Actually, I did start with gonum :)) but I thought it was a large dependency and I only needed a few funcs from it, so I decided to

Re: [go-nuts] How do you implement and use Context.Done?

2017-02-19 Thread Sina Siadat
normal send/receive to a channel, only one receiver receives the value sent to a channel. But with this pattern, all goroutines that are receiving from that channel will be notified. Sina Siadat On Monday, February 20, 2017 at 2:43:26 AM UTC+3:30, Matt Harden wrote: Done does not need

Re: [go-nuts] Re: How could the body for a func be "provided by runtime"?

2017-02-09 Thread Sina Siadat
Thanks for the clarification. On Friday, February 10, 2017 at 3:50:15 AM UTC+3:30, Ian Lance Taylor wrote: > > On Thu, Feb 9, 2017 at 4:16 PM, Sina Siadat <sia...@gmail.com > > wrote: > > > > One thing I still don't understand is the cases when go:linkname is

Re: [go-nuts] Re: How could the body for a func be "provided by runtime"?

2017-02-09 Thread Sina Siadat
Lance Taylor wrote: > > On Thu, Feb 9, 2017 at 5:19 AM, Sina Siadat <sia...@gmail.com > > wrote: > > Thank you! > > > > To make sure I understand what is going on I tried to reproduce the same > > thing. But I can't get the compiler to find the definition of

[go-nuts] Re: How could the body for a func be "provided by runtime"?

2017-02-09 Thread Sina Siadat
the hello.hello and greet.hello functions. What am I doing wrong? On Thursday, February 9, 2017 at 4:10:21 PM UTC+3:30, Christian Joergensen wrote: > > On Thursday, February 9, 2017 at 1:15:00 PM UTC+1, Sina Siadat wrote: >> >> But can't find how the compiler connects the two.

[go-nuts] How could the body for a func be "provided by runtime"?

2017-02-09 Thread Sina Siadat
Hi! In $GOROOT/src/sync/mutex.go:19 there is a function declaration like this: func throw(string) // provided by runtime The function body is missing. I was wondering what is meant by "provided by runtime" and how it is done. I am guessing this is the same as the throw func defined in

[go-nuts] net/http/httptrace: new hook for end of request life cycle (please comment and review)

2016-08-04 Thread Sina Siadat
Hi go-nuts, I have been working on a new httptrace hook to find out the end of a request life cycle. This new hook (RequestCompleted) is called with a provided error indicating whether the request was completed successfully. I was wondering if I could get your opinions and comments about it.