John B <(E-Mail Removed)> wrote:
<snip>
> The first, it adds a reference.
> Unless its a value type (or immutable ref type) then it will add a copy.
> Is dog a struct?
Immutable reference types are just like mutable reference types - no
copy is taken. It just so happens that you can't change the data within
the object. Indeed, it would be supremely pointless to take a copy of
the object given that its contents can't be changed anyway!
--
Jon Skeet - <(E-Mail Removed)>
http://www.pobox.com/~skeet Blog:
http://www.msmvps.com/jon.skeet
If replying to the group, please do not mail me too