[go-nuts] Re: Java version of keydb

2020-12-13 Thread da...@suarezhouse.net
Super interesting. Did you happen to catch the runtime memory avg, median, max and current "executable" file size difference? On Saturday, December 12, 2020 at 1:04:42 PM UTC-6 ren...@ix.netcom.com wrote: > Hi all, > > I thought this might be of interest to some. I released a Java version of

Re: [go-nuts] Generics - please provide real life problems

2020-12-31 Thread da...@suarezhouse.net
Real use cases have been provided it appears for both why generics can be good and how they can be used negligently (love the sextuple example BTW). I know many things in programming can be used the wrong way but does generics potentially cross a threshold where the writer should add an import

[go-nuts] Generics Error - How to fix?

2021-01-01 Thread da...@suarezhouse.net
I thought I read the generics doc well but.. :-) Help is appreciated: I instantiate a generic table example here in line 41: https://go2goplay.golang.org/p/SadxA0khqx7 Then I use it in lines 42 and 43. The errors I get are below: prog.go2:67:10: cannot use generic type Table[colA, colB, colC

[go-nuts] Re: Generics Error - How to fix?

2021-01-01 Thread da...@suarezhouse.net
using constraints as of now, just basic interface so more confusing on why it would expect those methods to require instantiation. Thanks! David On Friday, January 1, 2021 at 9:06:15 AM UTC-6 da...@suarezhouse.net wrote: > I thought I read the generics doc well but.. :-) Help is appreciate

Re: [go-nuts] Generics Error - How to fix?

2021-01-01 Thread da...@suarezhouse.net
You need to declare the type parameters in the method definitions too. > Something like this works OK: > > https://go2goplay.golang.org/p/ZUAVncRrmZW > > cheers, > rog. > > On Fri, 1 Jan 2021 at 15:06, da...@suarezhouse.net > wrote: > >> I thought I read th

[go-nuts] Re: Generics Error - How to fix?

2021-01-01 Thread da...@suarezhouse.net
gt; } > } > > This then breaks because t.rows is a slice of interface{}, not a slice of > Row. So I changed it to []Row. Then fixing your Println's to Printf's, > this gives https://go2goplay.golang.org/p/dAnPU_r0DpM and now it runs. > > However, I think this sti

Re: [go-nuts] Generics Error - How to fix?

2021-01-01 Thread da...@suarezhouse.net
https://go2goplay.golang.org/p/VMFOcI91i4X > > On Jan 1, 2021, at 1:56 PM, da...@suarezhouse.net > wrote: > > I am wondering if this is also something easy for the more experienced > folks here. > > I took the example from Rog: https://go2goplay.golang.org/p/ZUAVncRrmZW >

Re: [go-nuts] Generics Error - How to fix?

2021-01-02 Thread da...@suarezhouse.net
David On 01/01/2021 6:38 PM roger peppe wrote: On Fri, 1 Jan 2021, 17:49 da...@suarezhouse.net, <da...@suarezhouse.net> wrote: First of all -- 

Re: [go-nuts] Error handling

2021-02-23 Thread da...@suarezhouse.net
This has been interesting to watch as I too have somehow been "converted" from java style exceptions to current go-style error flow as preference. In the first example you just shared, I think if you elaborate the comments, "at this point all files are open, if any fail, others are closed", yo

Re: [go-nuts] Re: WASM Performance

2021-09-05 Thread da...@suarezhouse.net
I had read an article that may be useful (format was different so may not be the same) --> https://github.com/diekmann/wasm-fizzbuzz (goes from basic WASM to Doom) The key thing in the Doom port that I recall was needed was to change the perspective of the owning thread (now the browser) so n