Hacker News new | past | comments | ask | show | jobs | submit login

What I meant is:

(0) Expand the templates at compile-time, in order to type-check the code.

(1) Don't generate target language code for each specific instantiation, though.

(2) Re-expand the templates (or some representation of them) at runtime.

It's a very silly implementation strategy, of course. But I don't see why it's fundamentally impossible to do this - it's just undesirable.

And, yes, I agree about generics being better.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: