2 ms·
As the article states, this only supports lists of pointer types. The result would be the same bad performance that Bjarne Stroustrup warns of in the cited talk
by opk 11y ago
As the article states, this only supports lists of pointer types. The result would be the same bad performance that Bjarne Stroustrup warns of in the cited talk on linked lists. Each of these pointers will be random memory positions giving you bad cache hits.
list_append needn't take a second argument that is assigned across. If you've got an array of structs, you can then initialise the struct members in place.