Why did I get the error “error C2259: … cannot instantiate abstract class”?
问题 Any help is appriciated. I'm working on a C++ factory pattern and i get this error. 1>c:\users\brian\documents\visual studio 2010\projects\cst276lab_3\guitar.hpp(456): error C2259: 'ElectricGuitarComponentFactory' : cannot instantiate abstract class This is my code: ///////////////////////guitar class//////////////////// class Guitar { private: std::string _name; protected: mutable std::auto_ptr< HeadStock > _HeadStock; protected: mutable std::auto_ptr< NeckStrap > _NeckStrap; protected: