3 ms·
I also refuse to touch templates. Never needed them, never liked them. When I work on code that utilizes templates in c++, it reaffirms this feeling.
by dgfitz 2y ago
I also refuse to touch templates. Never needed them, never liked them. When I work on code that utilizes templates in c++, it reaffirms this feeling.
- otabdeveloper4 2y agoI hope programming isn't your day job.
- GuB-42 2y agoBut how are you writing generic code then? C preprocessor macros? Abstract classes? No genericity at all? C preprocessor macros are a hack, they are useful, but they come with plenty of issues. If you are using macros, there is a good chance there is a superior solution that uses templates. Abstract classes impact performance, sometimes significantly, and it doesn't solve all problems templates solve. If you don't care, then you would probably be better off doing Java (or languages in the same family) than C++. If you are not using genericity at all, it may actually be a good thing! Too much abstraction is a common problem. But sometimes you need it. Refusing to use generics will limit what you can do. And if it is your job, it will probably limit your pay too.