Click here to Skip to main content
15,912,205 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Determining DLL location? Pin
Nemanja Trifunovic28-Mar-03 7:02
Nemanja Trifunovic28-Mar-03 7:02 
AnswerRe: Determining DLL location? Pin
Big Art28-Mar-03 7:03
Big Art28-Mar-03 7:03 
AnswerRe: Determining DLL location? Pin
RobJones29-Mar-03 6:54
RobJones29-Mar-03 6:54 
AnswerRe: Determining DLL location? Pin
Justin Cooke31-Mar-03 11:29
Justin Cooke31-Mar-03 11:29 
GeneralSOAP and client certificates Pin
Le centriste28-Mar-03 6:52
Le centriste28-Mar-03 6:52 
GeneralConstructor & Destructor Pin
Makover28-Mar-03 6:08
Makover28-Mar-03 6:08 
GeneralRe: Constructor & Destructor Pin
Chris Losinger28-Mar-03 6:11
professionalChris Losinger28-Mar-03 6:11 
GeneralRe: Constructor & Destructor Pin
Daniel Turini28-Mar-03 6:20
Daniel Turini28-Mar-03 6:20 
Makover wrote:
1)Is it OK if I do nothing in the constructor – all initializations are done in the initialization list and the body of the Ctor is empty, i.e {}?
Granted no initialization can throw an exception, yes.
IMHO, this style is ugly, but it's only a matter of personal taste, no problem at all.

Makover wrote:
2)In one of the class methods I open, read and close a file. In another one I open, write and close an other file. Should I do something in the destructor? I have no class members for these streams so… In any case, Is it OK to leave a Dtor empty (actually not even declaring a Dtor) if there is no allocation on the heap throughout the class (no ‘new’)?
Assuming it's a base class, yes. But it's a good practice to declare a virtual destructor on each class, even if empty, this will save you some headaches in the future and will introduce no overhead (or almost no overhead, depending on your compiler).



It's not the fall that kills you: it's the sudden stop - Down by Law, Jim Jamursch (1986)
GeneralRe: Constructor & Destructor Pin
Makover28-Mar-03 6:37
Makover28-Mar-03 6:37 
GeneralRe: Constructor & Destructor Pin
Maximilien28-Mar-03 6:49
Maximilien28-Mar-03 6:49 
GeneralRe: Constructor & Destructor Pin
Alvaro Mendez28-Mar-03 8:18
Alvaro Mendez28-Mar-03 8:18 
GeneralRe: Constructor & Destructor Pin
Tim Smith28-Mar-03 7:25
Tim Smith28-Mar-03 7:25 
GeneralRe: Constructor & Destructor Pin
jbarton28-Mar-03 7:36
jbarton28-Mar-03 7:36 
GeneralBuild like Visual Studio Pin
calgonit28-Mar-03 5:48
calgonit28-Mar-03 5:48 
GeneralOutlook Automation :-( ( attachment) Pin
Braulio Dez28-Mar-03 5:28
Braulio Dez28-Mar-03 5:28 
GeneralSolution... sh*tty automation Pin
Braulio Dez28-Mar-03 5:47
Braulio Dez28-Mar-03 5:47 
Generaldialog editor question (fine tuning the position of one control) Pin
Joan M28-Mar-03 5:21
professionalJoan M28-Mar-03 5:21 
GeneralRe: dialog editor question (fine tuning the position of one control) Pin
Big Art28-Mar-03 5:33
Big Art28-Mar-03 5:33 
GeneralRe: dialog editor question (fine tuning the position of one control) Pin
Joan M28-Mar-03 5:39
professionalJoan M28-Mar-03 5:39 
GeneralRe: dialog editor question (fine tuning the position of one control) Pin
Big Art28-Mar-03 5:57
Big Art28-Mar-03 5:57 
GeneralRe: dialog editor question (fine tuning the position of one control) Pin
Joan M28-Mar-03 6:15
professionalJoan M28-Mar-03 6:15 
GeneralRe: dialog editor question (fine tuning the position of one control) Pin
Big Art28-Mar-03 6:51
Big Art28-Mar-03 6:51 
GeneralRe: dialog editor question (fine tuning the position of one control) Pin
Joan M28-Mar-03 7:05
professionalJoan M28-Mar-03 7:05 
GeneralRe: dialog editor question (fine tuning the position of one control) Pin
Big Art28-Mar-03 7:19
Big Art28-Mar-03 7:19 
GeneralRe: dialog editor question (fine tuning the position of one control) Pin
Joan M28-Mar-03 7:27
professionalJoan M28-Mar-03 7:27 

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.