471,610 Members | 1,355 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,610 software developers and data experts.

struct type

Seems like I am going back to basics.

Question is what happence if a ref type is in a struct instance, is it
declared on stack or heap?

Thanks.
Dec 7 '05 #1
2 1085
Pohihihi wrote:
Seems like I am going back to basics.

Question is what happence if a ref type is in a struct instance, is it
declared on stack or heap?


See http://www.pobox.com/~skeet/csharp/memory.html

Jon

Dec 7 '05 #2
All reference type objects are allocated on the heap.

Dec 7 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

67 posts views Thread by S.Tobias | last post: by
10 posts views Thread by Rick Anderson | last post: by
19 posts views Thread by Russell Shaw | last post: by
6 posts views Thread by S.Tobias | last post: by
12 posts views Thread by Sadeq | last post: by
20 posts views Thread by ma0001yu | last post: by
9 posts views Thread by werasm | last post: by
28 posts views Thread by Bill | last post: by
1 post views Thread by XIAOLAOHU | last post: by
reply views Thread by leo001 | last post: by
reply views Thread by MichaelMortimer | last post: by
reply views Thread by CCCYYYY | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.