[go-nuts] Re: [RFC] Yet another proposal for Go2 error handling

2023-06-04 Thread Justin Israel
On Monday, June 5, 2023 at 4:17:17 AM UTC+12 Shulhan wrote: Dear gophers, I have been reading several proposals about error handling couple of months ago and today a light bulb come upon me, and then I write as much as I can think. I am not sure if its good or bad idea or even possible to i

Re: [go-nuts] 9 is prime if it's a hot day

2023-06-04 Thread Sven Anderson
Bakul Shah schrieb am Mo. 5. Juni 2023 um 00:00: > Find the following paper and all will be revealed! May be. > > "Measuring The Primadona Factor For Odd Numbers" by Y. Ronen et al. > > PS: I think Rob's explanation is incorrect! 9 is shown to be *not* a > prime possibly *because* it was a hot da

Re: [go-nuts] call for data on HTTP routing

2023-06-04 Thread Andrew Harris
I wanted to make a quick observation w/r/t Ian's suggestion of not registering ambiguous patterns. The tradeoff isn't ultimately about what behaviors can be associated with what routes, but around what is required to register routes. To intentionally use the kinds of routes we'd interpret as am

Re: [go-nuts] Detecting race conditions

2023-06-04 Thread 'Axel Wagner' via golang-nuts
I think the race detector is already relatively good at this. Like, AIUI, it keeps track of the partial order of events and checks if that is consistent and doesn't *purely* rely on writes actually happen concurrently. I suspect (based on little) that in this case, the synchronization points that l

Re: [go-nuts] [RFC] Yet another proposal for Go2 error handling

2023-06-04 Thread Ian Lance Taylor
On Sun, Jun 4, 2023 at 9:17 AM Shulhan wrote: > > I have been reading several proposals about error handling couple of > months ago and today a light bulb come upon me, and then I write as much > as I can think. I am not sure if its good or bad idea or even possible > to implement. > > In this po

Re: [go-nuts] Detecting race conditions

2023-06-04 Thread Stephen Illingworth
But it does not introduce false positives. It exposes true positives. The race are still there, even if the race detector can not detect them. Note that the race detector is a heuristic. It will never find all race conditions, only the ones encountered in the actual run. This is a great poin

[go-nuts] [RFC] Yet another proposal for Go2 error handling

2023-06-04 Thread Shulhan
Dear gophers, I have been reading several proposals about error handling couple of months ago and today a light bulb come upon me, and then I write as much as I can think. I am not sure if its good or bad idea or even possible to implement. In this post, I will try as concise as possible. The fu

Re: [go-nuts] Equivalence of types declared with equals

2023-06-04 Thread Duncan Harris
Thanks. So the only issue is that maybe the error message is a bit sub-optimal. Duncan On Sun, 4 Jun 2023 at 06:35, Axel Wagner wrote: > That's a type alias, though. Not a type definition. > > The real issue is this part of the spec > : > >> Two struct ty

Re: [go-nuts] If a pointer type implements a method in an interface, then its value type variable cannot be assigned to the corresponding interface. But it works the other way around!

2023-06-04 Thread 王谦铭
Thanks for your explanation. Ian Lance Taylor 于2023年6月4日周日 01:09写道: > On Sat, Jun 3, 2023 at 10:05 AM 王谦铭 wrote: > > > > If a pointer type implements a method in an interface, then its value > type variable cannot be assigned to the corresponding interface. > Conversely, if a value type impleme