Click here to Skip to main content
15,891,762 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: can we make class cant be derived at all? PinPopular
Rajesh R Subramanian23-Oct-09 21:53
professionalRajesh R Subramanian23-Oct-09 21:53 
GeneralRe: can we make class cant be derived at all? Pin
theCPkid23-Oct-09 22:00
theCPkid23-Oct-09 22:00 
GeneralRe: can we make class cant be derived at all? Pin
Rajesh R Subramanian23-Oct-09 22:14
professionalRajesh R Subramanian23-Oct-09 22:14 
GeneralRe: can we make class cant be derived at all? Pin
theCPkid23-Oct-09 22:25
theCPkid23-Oct-09 22:25 
GeneralRe: can we make class cant be derived at all? Pin
Rajesh R Subramanian23-Oct-09 22:36
professionalRajesh R Subramanian23-Oct-09 22:36 
GeneralRe: can we make class cant be derived at all? Pin
Richard MacCutchan24-Oct-09 7:15
mveRichard MacCutchan24-Oct-09 7:15 
GeneralRe: can we make class cant be derived at all? Pin
Rajesh R Subramanian24-Oct-09 7:38
professionalRajesh R Subramanian24-Oct-09 7:38 
AnswerRe: can we make class cant be derived at all? Pin
Rajesh R Subramanian23-Oct-09 19:31
professionalRajesh R Subramanian23-Oct-09 19:31 
class CSealed
{
   CSealed(){}
   CSealed(const CSealed& ref){}
};

class some:public CSealed
{
   //whatever
};

int _tmain(int argc, _TCHAR* argv[])
{
   some s;
   return 0;
}


This won't compile: C2248!

Of course I assume that you know the other 'quirks' associated with keeping a class constructor as private. Let me know if you need more information.


“Follow your bliss.” – Joseph Campbell

AnswerRe: can we make class cant be derived at all? Pin
Kushagra Tiwari23-Oct-09 21:33
Kushagra Tiwari23-Oct-09 21:33 
AnswerRe: can we make class cant be derived at all? [modified] Pin
Nuri Ismail23-Oct-09 22:27
Nuri Ismail23-Oct-09 22:27 
Questionscanner Driver Pin
randydom23-Oct-09 11:03
randydom23-Oct-09 11:03 
QuestionRe: scanner Driver Pin
NitinMakwana8-Jan-10 1:10
NitinMakwana8-Jan-10 1:10 
QuestionMemory Leak Pin
BarryPearlman23-Oct-09 10:51
BarryPearlman23-Oct-09 10:51 
AnswerRe: Memory Leak Pin
«_Superman_»23-Oct-09 12:21
professional«_Superman_»23-Oct-09 12:21 
AnswerRe: Memory Leak Pin
BarryPearlman25-Oct-09 3:56
BarryPearlman25-Oct-09 3:56 
GeneralRe: Memory Leak Pin
«_Superman_»25-Oct-09 8:43
professional«_Superman_»25-Oct-09 8:43 
AnswerRe: Memory Leak Pin
PJ Arends23-Oct-09 12:37
professionalPJ Arends23-Oct-09 12:37 
GeneralRe: Memory Leak Pin
BarryPearlman23-Oct-09 15:12
BarryPearlman23-Oct-09 15:12 
Questionint treated as binary no. Pin
Manmohan2923-Oct-09 10:41
Manmohan2923-Oct-09 10:41 
AnswerRe: int treated as binary no. Pin
David Crow23-Oct-09 10:45
David Crow23-Oct-09 10:45 
GeneralRe: int treated as binary no. Pin
Manmohan2923-Oct-09 10:58
Manmohan2923-Oct-09 10:58 
AnswerRe: int treated as binary no. Pin
David Crow23-Oct-09 11:04
David Crow23-Oct-09 11:04 
GeneralRe: int treated as binary no. Pin
Manmohan2923-Oct-09 11:16
Manmohan2923-Oct-09 11:16 
GeneralRe: int treated as binary no. Pin
David Crow23-Oct-09 15:08
David Crow23-Oct-09 15:08 
QuestionScrollbars are shown incorrectly. Pin
Nikz223-Oct-09 10:01
Nikz223-Oct-09 10:01 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.