Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does ^ after a type mean in c++?

Tags:

syntax

c++-cli

I have some c++ code with function return types declared as string^ or IEnumerable<String^>^, what does that mean?

edits: c#->c++/cli

like image 904
Charles Ma Avatar asked Jan 04 '11 22:01

Charles Ma


1 Answers

It doesn't mean anything in C#. You're looking at source code for C++/CLI, not C#.

See http://en.wikipedia.org/wiki/C%2B%2B/CLI for a brief introduction.

The carat symbol basically means "this is a GC-tracked reference".

like image 193
Eric Lippert Avatar answered Sep 28 '22 10:09

Eric Lippert