Click here to Skip to main content
15,902,447 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Disecting a PE File Pin
Richard MacCutchan30-Jun-17 21:30
mveRichard MacCutchan30-Jun-17 21:30 
GeneralRe: Disecting a PE File Pin
Bram van Kampen2-Jul-17 13:26
Bram van Kampen2-Jul-17 13:26 
GeneralRe: Disecting a PE File Pin
Richard MacCutchan2-Jul-17 21:42
mveRichard MacCutchan2-Jul-17 21:42 
QuestionStreamin proc for Rich edit Pin
ForNow16-Jun-17 9:27
ForNow16-Jun-17 9:27 
QuestionRe: Streamin proc for Rich edit Pin
David Crow16-Jun-17 17:40
David Crow16-Jun-17 17:40 
AnswerRe: Streamin proc for Rich edit Pin
ForNow17-Jun-17 15:43
ForNow17-Jun-17 15:43 
GeneralRe: Streamin proc for Rich edit Pin
David Crow17-Jun-17 16:09
David Crow17-Jun-17 16:09 
GeneralRe: Streamin proc for Rich edit Pin
ForNow17-Jun-17 16:28
ForNow17-Jun-17 16:28 
Questionikspropertset declaring variable ksps Pin
Member 1326135415-Jun-17 5:58
Member 1326135415-Jun-17 5:58 
AnswerRe: ikspropertset declaring variable ksps Pin
Richard MacCutchan15-Jun-17 6:13
mveRichard MacCutchan15-Jun-17 6:13 
GeneralRe: ikspropertset declaring variable ksps Pin
Member 1326135415-Jun-17 8:35
Member 1326135415-Jun-17 8:35 
GeneralRe: ikspropertset declaring variable ksps Pin
Richard MacCutchan15-Jun-17 8:49
mveRichard MacCutchan15-Jun-17 8:49 
GeneralRe: ikspropertset declaring variable ksps Pin
jeron116-Jun-17 5:31
jeron116-Jun-17 5:31 
QuestionHow to make LDPC parity check matrix H from non-systematic to systematic in C/C++ Pin
Member 1326117515-Jun-17 1:42
Member 1326117515-Jun-17 1:42 
QuestionDynamically create memory based on 2 different struture templates Pin
manoharbalu14-Jun-17 1:19
manoharbalu14-Jun-17 1:19 
AnswerRe: Dynamically create memory based on 2 different struture templates Pin
Richard MacCutchan14-Jun-17 4:32
mveRichard MacCutchan14-Jun-17 4:32 
GeneralRe: Dynamically create memory based on 2 different struture templates Pin
manoharbalu14-Jun-17 20:27
manoharbalu14-Jun-17 20:27 
GeneralRe: Dynamically create memory based on 2 different struture templates Pin
Richard MacCutchan14-Jun-17 22:40
mveRichard MacCutchan14-Jun-17 22:40 
GeneralRe: Dynamically create memory based on 2 different struture templates Pin
manoharbalu14-Jun-17 22:44
manoharbalu14-Jun-17 22:44 
GeneralRe: Dynamically create memory based on 2 different struture templates Pin
Richard MacCutchan14-Jun-17 23:18
mveRichard MacCutchan14-Jun-17 23:18 
GeneralRe: Dynamically create memory based on 2 different struture templates Pin
manoharbalu15-Jun-17 0:34
manoharbalu15-Jun-17 0:34 
GeneralRe: Dynamically create memory based on 2 different struture templates Pin
Richard MacCutchan15-Jun-17 1:11
mveRichard MacCutchan15-Jun-17 1:11 
GeneralRe: Dynamically create memory based on 2 different struture templates Pin
leon de boer15-Jun-17 8:06
leon de boer15-Jun-17 8:06 
GeneralRe: Dynamically create memory based on 2 different struture templates Pin
manoharbalu15-Jun-17 19:54
manoharbalu15-Jun-17 19:54 
GeneralRe: Dynamically create memory based on 2 different struture templates Pin
leon de boer16-Jun-17 4:14
leon de boer16-Jun-17 4:14 
First let me say you are making a mountain out of a molehill ... "test->" is a dead easy string to pick off with a text auto-replace on. Would take me about 30sec to do on code throughout the project.

You could also do what a good programmer would do and get rid of the stupid global pointer and pass it into the functions on the local interface. You can keep it as test on the local interface but pass in lets_use_it.test1. You make your code better, safer and it is simply extending a few local interfaces. That is what I would actually do .. globals are evil Smile | :)

The question to ask yourself is why are you using the global pointer rather than having a pointer parameter on the functions that use the global?

That all said you could keep the pointer "as is" if you want by typecasting but it is frowned on Frown | :-(
struct test1* test = lets_use_it.test1; /* Is perfectly valid  */

In vino veritas


modified 16-Jun-17 10:22am.

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.