Comment

Comment by AndyKelley

The thing I miss most in C when I don't cheat and use a couple C++ features is templates. Specifically, a dynamically sized List implementation that is type-generic.

If you do this in pure C, you have to pick your poison:

1. preprocessor abuse

2. void *

3. multiple redundant implementations of the data structure

Dynamically sized lists are used so often, that this tends to be a problem in almost every C project. I wonder what the author's solution is to this dilemma.

parent AndyKelley 10 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton