Storing multiple types of a templated class into a container

后端 未结 2 734
南方客
南方客 2021-01-21 13:47

If I have a class with a template:

template
class foo{
    T m_a;

    foo(T a){
        m_a = a;
    };

    ~foo(){

    };
};
2条回答
  •  逝去的感伤
    2021-01-21 14:32

    Different instantiations of a class-template are different (from the compilers perspective completely unrelated) types, so this question applies.

提交回复
热议问题