Stuipid Carrot Question

Please support our C++ advertiser: Intel Parallel Studio Home
Thread Solved

Join Date: Feb 2005
Posts: 181
Reputation: Paul.Esson is an unknown quantity at this point 
Solved Threads: 10
Paul.Esson's Avatar
Paul.Esson Paul.Esson is offline Offline
Junior Poster

Stuipid Carrot Question

 
0
  #1
Mar 25th, 2008
After looking at compile errors because I was not overriding this function ( although being convinced that I was) I have a query for all you C++ buffs in the audiance. What does the ^ do in the following line.

  1. virtual System::Object ^ Clone(void) override;

I know this is quite possably a stupid question and for that I am quite sorry.
Reply With Quote Quick reply to this message  
Join Date: Feb 2005
Posts: 181
Reputation: Paul.Esson is an unknown quantity at this point 
Solved Threads: 10
Paul.Esson's Avatar
Paul.Esson Paul.Esson is offline Offline
Junior Poster

Re: Stuipid Carrot Question

 
0
  #2
Mar 25th, 2008
Ok, Replying to my own thread here, But I have had a look around the net and from what I can tell it refers to a reference to a managed type in .NET. I may be wrong ( since I have seen nothing that has said this yet )
Reply With Quote Quick reply to this message  
Join Date: Mar 2008
Posts: 268
Reputation: Traicey is an unknown quantity at this point 
Solved Threads: 19
Traicey's Avatar
Traicey Traicey is offline Offline
Posting Whiz in Training

Re: Stuipid Carrot Question

 
1
  #3
Mar 25th, 2008
As u said........ a caret [^] is a managed reference (usually called a handle in C++/CLI) is a reference to a managed .NET object. Managed object's lifetimes that are controlled by the .NET garbage collection system which needs to be able to track all references to managed objects. Having separate syntax for managed references / handles and regular native references helps makes this distinction explicit in the code and avoid confusion between managed / garbage collected .NET types and unmanaged native types whose lifetimes must still be managed explicitly by the programmer.
Some people get so rich they lose all respect for humanity. That's how rich I want to be.
Reply With Quote Quick reply to this message  
Reply

This thread has been marked solved.
Perhaps start a new thread instead?
Message:



Other Threads in the C++ Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC