CList Errors & Copy Constructor problems - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


CList Errors & Copy Constructor problems

kvillineskvillines Posts: 35Member
Question 1:
I have never used CList but I need to copy some objects into one for storage. I thought I could write a class that inherits from CList but that is not working. I am doing the following and keep getting errors.

#include "Shape.h"

class CShapelist : public CList
virtual ~CShapelist();


I am doing something wrong and have exhausted the books that I have. There isn't alot of samples or indepth info on CList.

Question 2:
My CShape copy constructor is compiling but I need to know if I need implementation since it is all in my class? And if it does nothing is the default to copy the whole object?

class CShape : public CWnd
// Construction
CShape(int m_nColor = 0, int m_lineColor = 2,
int m_lineSize = 12);
CShape( const CShape& a ) {} // Copy constructor

Sign In or Register to comment.