News for hackers. Stuff that matters.
Re:Generics enabled by default in Go tip by bouncycastle on Saturday August 21, 2021 @12:36AM (#28254229)
Singly linked lists are something from CS1 where you learn about data structures. You rarely use them in practice. In most cases slices and maps do the job fine.
Re:Generics enabled by default in Go tip by dilyevsky on Saturday August 21, 2021 @01:05AM (#28254369)
They also have absolutely terrible performance due to poor cache locality and putting pressure on GC
Re:Generics enabled by default in Go tip by pjmlp on Sunday August 22, 2021 @06:12AM (#28264244)
There are many ways to implement a list, including backed by arrays.

That is what those CS algorithm and data structures lectures are for.

Re:Generics enabled by default in Go tip by puddingforears on Saturday August 21, 2021 @03:06AM (#28254913)
They make a great stack, though. Cheap to use and easy to implement.
Re:Generics enabled by default in Go tip by snovv_crash on Saturday August 21, 2021 @04:08AM (#28255154)
Use a deque at least and amortize the heap allocations...
Re:Generics enabled by default in Go tip by puddingforears on Saturday August 21, 2021 @10:31AM (#28257318)
With generics I could justify the extra engineering work to make such a deque!
Re:Generics enabled by default in Go tip by bouncycastle on Saturday August 21, 2021 @01:10AM (#28254387)
Source?
Re:Generics enabled by default in Go tip by mseepgood on Saturday August 21, 2021 @03:51AM (#28255068)
CS201
Re:Generics enabled by default in Go tip by bouncycastle on Sunday August 22, 2021 @11:34AM (#28266292)
Ok genius, explain how exactly what the OP meant?