Why Templates?
Ivan Senji
ivan.senji_REMOVE_ at _THIS__gmail.com
Sun Mar 5 09:27:41 PST 2006
Hasan Aljudy wrote:
> Ivan Senji wrote:
>
>> Hasan Aljudy wrote:
>>
>>> I feel the same.
>>> I do come from C++ background, but I just hate templates! (Now I hate
>>> C++ itself :)
>>> I think templates were introduced in C++ to solve the "no-base-class"
>>> problem.
>>
>>
>>
>> It is the other way around, languages introduce common base class to
>> solve the no-templates-problem. (Not a very good solution IMO).
>>
>
> No. The Object base class fits perfectly into the object oriented
> paradigm. Templates do not, hence a hack.
Maybe so, but I see a common Object base class a hack to solve many
problems that are simple and efficient to solve with templates. For
example containers. Containers in Java(before templates)-style and
C#(before templates)-style are nothing but inefficient hacks.
And one more thing <insert what Lars replyed> :)
More information about the Digitalmars-d
mailing list