Click here to Skip to main content
14,700,235 members
Home » Discussions » Managed C++/CLI
   

Managed C++/CLI

 
GeneralRe: Detecting option '-Gr' in MSVC Pin
Randor 12-Feb-18 12:19
professional Randor 12-Feb-18 12:19 
QuestionIMPLEMENTING AND EXERCISING A FRACTION CLASS Pin
Member 1362061912-Jan-18 13:42
MemberMember 1362061912-Jan-18 13:42 
AnswerRe: IMPLEMENTING AND EXERCISING A FRACTION CLASS Pin
Richard MacCutchan12-Jan-18 23:18
mveRichard MacCutchan12-Jan-18 23:18 
QuestionReal-Time push server in C++ may i use it as unmanaged dlls so i can work on it using C# ? Pin
Ali Al-Masry4-Jan-18 3:02
MemberAli Al-Masry4-Jan-18 3:02 
AnswerRe: Real-Time push server in C++ may i use it as unmanaged dlls so i can work on it using C# ? Pin
John Schroedl5-Jan-18 15:27
professionalJohn Schroedl5-Jan-18 15:27 
QuestionC++/CLI and .Net Entity Framework Pin
SheepSpeech4-Dec-17 1:20
MemberSheepSpeech4-Dec-17 1:20 
QuestionMessage Closed Pin
27-Nov-17 22:16
MemberMember 1354502927-Nov-17 22:16 
AnswerRe: project $50 reward need in 24 hours Pin
Pete O'Hanlon27-Nov-17 22:18
subeditorPete O'Hanlon27-Nov-17 22:18 
QuestionISSUE - TCP/IP sockets in MFC VS2017 Pin
D.Manivelan21-Nov-17 2:22
MemberD.Manivelan21-Nov-17 2:22 
AnswerRe: ISSUE - TCP/IP sockets in MFC VS2017 Pin
Jochen Arndt21-Nov-17 2:59
professionalJochen Arndt21-Nov-17 2:59 
AnswerRe: ISSUE - TCP/IP sockets in MFC VS2017 Pin
jschell22-Nov-17 10:05
Memberjschell22-Nov-17 10:05 
I question how you are determining it is wrong. You code does not demonstrate that.

HOWEVER....

You are declaring a data entity on the stack. Then you are RETURNING part of that data entity from the method.

That is ALWAYS wrong.

And I suspect that is your problem.

The calling code also uses the stack. And will reuse exactly the same memory as where you are attempting to put a value if it wants to. For example if you are calling a method to 'print' the returned value in some way. Thus overwriting it. And that would cause a "junk" value either now or in the future.
QuestionTo sort an array of integer's with recursive functions ? Pin
Tarun Jha18-Nov-17 4:46
MemberTarun Jha18-Nov-17 4:46 
GeneralRe: To sort an array of integer's with recursive functions ? Pin
PIEBALDconsult18-Nov-17 4:56
professionalPIEBALDconsult18-Nov-17 4:56 
SuggestionTo find hcf of n number by using only loops. Pin
Tarun Jha4-Nov-17 3:20
MemberTarun Jha4-Nov-17 3:20 
GeneralRe: To find hcf of n number by using only loops. Pin
Richard MacCutchan4-Nov-17 22:10
mveRichard MacCutchan4-Nov-17 22:10 
GeneralRe: To find hcf of n number by using only loops. Pin
Tarun Jha7-Nov-17 7:20
MemberTarun Jha7-Nov-17 7:20 
GeneralRe: To find hcf of n number by using only loops. Pin
Richard MacCutchan7-Nov-17 8:00
mveRichard MacCutchan7-Nov-17 8:00 
QuestionIs every C# feature available in C++/Managed ? Pin
Maximilien11-Oct-17 8:26
MemberMaximilien11-Oct-17 8:26 
AnswerRe: Is every C# feature available in C++/Managed ? Pin
Richard MacCutchan11-Oct-17 10:50
mveRichard MacCutchan11-Oct-17 10:50 
AnswerRe: Is every C# feature available in C++/Managed ? Pin
John Schroedl28-Nov-17 3:03
professionalJohn Schroedl28-Nov-17 3:03 
Questionc++ Pin
Member 1340521911-Sep-17 22:51
MemberMember 1340521911-Sep-17 22:51 
AnswerRe: c++ Pin
Jochen Arndt11-Sep-17 23:41
professionalJochen Arndt11-Sep-17 23:41 
QuestionGet USB drive letter Pin
Member 101933363-Aug-17 1:22
MemberMember 101933363-Aug-17 1:22 
SuggestionRe: Get USB drive letter Pin
Jochen Arndt3-Aug-17 2:10
professionalJochen Arndt3-Aug-17 2:10 
GeneralRe: Get USB drive letter Pin
Member 101933363-Aug-17 3:31
MemberMember 101933363-Aug-17 3:31 

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.