c# - Does it make sense to pass a "reference type" to a method as a parameter with 'ref' key? -


possible duplicate:
c#: use of “ref” reference-type variables?

hi,

does make sense pass "reference type" method parameter 'ref' key?

or nonsense reference type not value type?

thanks!

it lets change reference variable itself, in addition object it's pointing to.

it makes sense if think might make variable point different object (or null) inside method.

otherwise, no.


Comments

Popular posts from this blog

Cursor error with postgresql, pgpool and php -

delphi - ESC/P programming! -

c++ - error: use of deleted function -