Click here to Skip to main content
15,926,507 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Casting thread functions Pin
Joe Moldovan24-Feb-01 14:34
Joe Moldovan24-Feb-01 14:34 
GeneralRe: Casting thread functions Pin
Tim Deveaux24-Feb-01 15:07
Tim Deveaux24-Feb-01 15:07 
GeneralRe: Casting thread functions Pin
Joe Moldovan24-Feb-01 18:21
Joe Moldovan24-Feb-01 18:21 
GeneralRe: Casting thread functions Pin
NormDroid25-Feb-01 5:41
professionalNormDroid25-Feb-01 5:41 
GeneralRe: Casting thread functions Pin
Tim Deveaux24-Feb-01 14:58
Tim Deveaux24-Feb-01 14:58 
GeneralRe: Casting thread functions Pin
Todd Wilson24-Feb-01 15:20
Todd Wilson24-Feb-01 15:20 
GeneralRe: Casting thread functions Pin
Tim Deveaux24-Feb-01 15:32
Tim Deveaux24-Feb-01 15:32 
GeneralRe: Casting thread functions Pin
Erik Funkenbusch26-Feb-01 12:55
Erik Funkenbusch26-Feb-01 12:55 
Actually, using a static is not portable either. It will probably work with most compilers, but technically it's undefined functionality. The compiler vendor is allowed to implement static members any way it chooses, so long as they follow certain rules. The static trick works primarily because a static member has the same function signature as non-static member in most implementations.

To be portable, you should use a non-member function and use the parameter passed to the function as a pointer to the object, however this also means you won't be able to access private or protected members through that pointer.


GeneralRe: Casting thread functions Pin
Todd Wilson26-Feb-01 13:13
Todd Wilson26-Feb-01 13:13 
GeneralRe: Casting thread functions Pin
Erik Funkenbusch26-Feb-01 13:32
Erik Funkenbusch26-Feb-01 13:32 
GeneralRe: Casting thread functions Pin
Joe Moldovan24-Feb-01 17:44
Joe Moldovan24-Feb-01 17:44 
GeneralRe: Casting thread functions Pin
Tim Deveaux25-Feb-01 5:13
Tim Deveaux25-Feb-01 5:13 
GeneralRe: Casting thread functions Pin
Erik Funkenbusch26-Feb-01 13:11
Erik Funkenbusch26-Feb-01 13:11 
GeneralRe: Casting thread functions Pin
Joe Moldovan26-Feb-01 19:45
Joe Moldovan26-Feb-01 19:45 
QuestionHow to use handle_wm_notify macro which comes with win32? Pin
Sachin23-Feb-01 23:04
Sachin23-Feb-01 23:04 
AnswerRe: How to use handle_wm_notify macro which comes with win32? Pin
Sardaukar24-Feb-01 1:23
Sardaukar24-Feb-01 1:23 
GeneralOnSize Pin
Starodubtsev Sergey23-Feb-01 22:53
Starodubtsev Sergey23-Feb-01 22:53 
GeneralRe: OnSize Pin
Erik Funkenbusch26-Feb-01 13:17
Erik Funkenbusch26-Feb-01 13:17 
Generaltitle text on the main frame Pin
Starodubtsev Sergey23-Feb-01 22:20
Starodubtsev Sergey23-Feb-01 22:20 
GeneralRe: title text on the main frame Pin
Christian Graus23-Feb-01 22:23
protectorChristian Graus23-Feb-01 22:23 
Generalcreate an exe file from another Pin
Sachin23-Feb-01 15:01
Sachin23-Feb-01 15:01 
GeneralRe: create an exe file from another Pin
Tim Deveaux24-Feb-01 4:14
Tim Deveaux24-Feb-01 4:14 
QuestionHow to install source patch with VC++? Pin
23-Feb-01 13:09
suss23-Feb-01 13:09 
QuestionHow to install source patch with VC++? Pin
23-Feb-01 13:08
suss23-Feb-01 13:08 
GeneralWinsock problem - PLEASE help Pin
23-Feb-01 11:11
suss23-Feb-01 11:11 

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.