Click here to Skip to main content
15,890,670 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: point reference VS value Pin
Stuart Dootson19-Apr-09 4:24
professionalStuart Dootson19-Apr-09 4:24 
GeneralRe: point reference VS value Pin
Luc Pattyn19-Apr-09 4:37
sitebuilderLuc Pattyn19-Apr-09 4:37 
GeneralRe: point reference VS value Pin
Stuart Dootson19-Apr-09 4:56
professionalStuart Dootson19-Apr-09 4:56 
GeneralRe: point reference VS value Pin
Luc Pattyn19-Apr-09 5:00
sitebuilderLuc Pattyn19-Apr-09 5:00 
GeneralRe: point reference VS value Pin
Stuart Dootson19-Apr-09 5:04
professionalStuart Dootson19-Apr-09 5:04 
GeneralRe: point reference VS value Pin
sharion19-Apr-09 5:25
sharion19-Apr-09 5:25 
GeneralRe: point reference VS value Pin
Stuart Dootson19-Apr-09 7:15
professionalStuart Dootson19-Apr-09 7:15 
GeneralRe: point reference VS value Pin
sharion20-Apr-09 18:30
sharion20-Apr-09 18:30 
The value of point str is changed when second it is allocated memory. Do you agree?

Stuart Dootson wrote:
Of course, the memory that str points at is no longer allocated, so you don't want to be using str after the GetMemory call!


Actually, str is allocated successfully after GetMemory.When you count the memory size of str between memory allocated two times you can draw this conclusion.

This snippet indicates a case of second memory allocated.In logical it may be weired.I post it only want to say GetMemory also change the point str when it passed by a point variable instead of point to a point(**) or reference to a point(*&).

Thanks a lot.
GeneralRe: point reference VS value Pin
Stuart Dootson20-Apr-09 19:40
professionalStuart Dootson20-Apr-09 19:40 
GeneralRe: point reference VS value Pin
sharion21-Apr-09 18:05
sharion21-Apr-09 18:05 
GeneralRe: point reference VS value Pin
Stuart Dootson21-Apr-09 21:39
professionalStuart Dootson21-Apr-09 21:39 
GeneralRe: point reference VS value Pin
sharion22-Apr-09 16:00
sharion22-Apr-09 16:00 
QuestionProblem with headers in VS 2008 [modified] Pin
mass8518-Apr-09 10:07
mass8518-Apr-09 10:07 
AnswerRe: Problem with headers in VS 2008 Pin
Luc Pattyn18-Apr-09 10:33
sitebuilderLuc Pattyn18-Apr-09 10:33 
GeneralRe: Problem with headers in VS 2008 Pin
mass8518-Apr-09 11:08
mass8518-Apr-09 11:08 
GeneralRe: Problem with headers in VS 2008 Pin
Stuart Dootson18-Apr-09 11:36
professionalStuart Dootson18-Apr-09 11:36 
GeneralRe: Problem with headers in VS 2008 Pin
mass8518-Apr-09 11:45
mass8518-Apr-09 11:45 
GeneralRe: Problem with headers in VS 2008 Pin
Stuart Dootson18-Apr-09 11:49
professionalStuart Dootson18-Apr-09 11:49 
GeneralRe: Problem with headers in VS 2008 Pin
Luc Pattyn18-Apr-09 11:57
sitebuilderLuc Pattyn18-Apr-09 11:57 
GeneralRe: Problem with headers in VS 2008 Pin
mass8518-Apr-09 12:00
mass8518-Apr-09 12:00 
Question[Message Deleted] Pin
marcusab18-Apr-09 9:16
marcusab18-Apr-09 9:16 
AnswerRe: How to copy/convert System::Object^(unsigned char) to local variable Pin
CPallini18-Apr-09 9:54
mveCPallini18-Apr-09 9:54 
Question880129 - class of matrix of complex numbers Pin
ilostmyid218-Apr-09 9:15
professionalilostmyid218-Apr-09 9:15 
AnswerRe: 880129 - class of matrix of complex numbers Pin
CPallini18-Apr-09 9:52
mveCPallini18-Apr-09 9:52 
GeneralRe: 880129 - class of matrix of complex numbers Pin
ilostmyid218-Apr-09 16:22
professionalilostmyid218-Apr-09 16:22 

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.