CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6
  1. #1
    Join Date
    Aug 2009
    Location
    Finally back in Alaska
    Posts
    141

    Question about tophat ^

    Hello all,

    Ive programmed for fun in visual basic for years and have been working on teaching myself c++ for the last 6 months or so and Ive been trying to teach myself the benefits of using pointers lately (trying to improve the speed of a project Ive been working on) now I have found all kinds of information on pointers and using indirection (* &) but I am having a problem of figuring out where the tophat ^ fits in to all this, I guess it is a pointer of some kind since it uses the -> to access its members, but what is the difference between ^ and *. After all my searching Ive been able to find very little on the net about the ^. I am not sure if I am even asking the right question to find the information. Could someone please point me to a reference on it so I could understand a little better?

    Thanks for taking the time to read through this,

    Richard

  2. #2
    Join Date
    Sep 2004
    Location
    Holland (land of the dope)
    Posts
    4,123

    Re: Question about tophat ^

    C++ has no ^. Managed C++ does.

  3. #3
    Join Date
    Oct 2008
    Location
    Cologne, Germany
    Posts
    756

    Re: Question about tophat ^

    it means it's a ref type (in managed c++ as already been mentioned)
    win7 x86, VS 2008 & 2010, C++/CLI, C#, .NET 3.5 & 4.0, VB.NET, VBA... WPF is comming

    remeber to give feedback you think my response deserves recognition? perhaps you may want to click the Rate this post link/button and add to my reputation

    private lessons are not an option so please don't ask for help in private, I won't replay

    if you use Opera and you'd like to have the tab-button functionality for the texteditor take a look at my Opera Tab-UserScirpt; and if you know how to stop firefox from jumping to the next control when you hit tab let me know

  4. #4
    Join Date
    Apr 2000
    Location
    Belgium (Europe)
    Posts
    4,626

    Re: Question about tophat ^

    ^ in C++ is an binary Xor operator though
    So C++ does have a ^, just not in relation to pointer/reference.

    IN managed C++, the right terminology would be saying that name^ is a handle to an object on the managed heap.

  5. #5
    Join Date
    Jun 2006
    Posts
    645

    Re: Question about tophat ^

    Is there a difference in the CSharp reference and managed C++ handle(^)? In other words what is the difference between a reference to object and handle to object? I understand that this is not a managed C++ forum and I would rarely ever work on that, yet it would be great if I get a short answer....
    Thanks
    Bhushan

  6. #6
    Join Date
    Jul 2002
    Posts
    2,543

    Re: Question about tophat ^

    C# reference and C++/CLI handle are exactly the same.
    All .NET languages are translated to the same Intermediate Language (MSIL), they are different only by syntax.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured