|
|
|
|
|
by codr7
426 days ago
|
|
This approach is also common in C: https://github.com/codr7/hacktical-c/tree/main/list One pretty big advantage is you get some help from the compiler making sure you mean what you say. As opposed to just blindly casting items and assuming no one forgot to put the list in their struct. Also the possibility to be part of multiple lists. |
|