Click here to Skip to main content
14,660,578 members

Welcome to the Lounge

   

For discussing anything related to a software developer's life but is not for programming questions. Got a programming question?

The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.
 
GeneralRe: If I see one more... Pin
Roger Wright8-Dec-08 18:27
professionalRoger Wright8-Dec-08 18:27 
GeneralRe: If I see one more... Pin
_Maxxx_8-Dec-08 18:35
professional_Maxxx_8-Dec-08 18:35 
GeneralRe: If I see one more... Pin
Roger Wright8-Dec-08 18:58
professionalRoger Wright8-Dec-08 18:58 
GeneralRe: If I see one more... Pin
_Maxxx_8-Dec-08 19:02
professional_Maxxx_8-Dec-08 19:02 
GeneralRe: If I see one more... Pin
Phil Martin8-Dec-08 18:34
professionalPhil Martin8-Dec-08 18:34 
GeneralRe: If I see one more... Pin
_Maxxx_8-Dec-08 18:42
professional_Maxxx_8-Dec-08 18:42 
GeneralRe: If I see one more... Pin
dmitri_sps9-Dec-08 13:40
Memberdmitri_sps9-Dec-08 13:40 
GeneralRe: If I see one more... Pin
Leslie Sanford8-Dec-08 18:42
MemberLeslie Sanford8-Dec-08 18:42 
Roger Wright wrote:
Excuse my ignorance, since I'm just trying to learn C#, but aren't all object types in C# passed by reference by default?


Yeah, but using the ref modifier is kind of like using a pointer to pointer in C or C++ (I'm taking a chance that you're familiar with C or C++).

void DoIt(int **x)
{
    *x = new int[256];
}

// ...
int *x;

DoIt(&x);

// Now x points to an array of 256 integers.


In C# the ref keyword lets us change what the specified object references, i.e. points to.
GeneralRe: If I see one more... Pin
Roger Wright8-Dec-08 18:53
professionalRoger Wright8-Dec-08 18:53 
GeneralRe: If I see one more... Pin
_Maxxx_8-Dec-08 19:00
professional_Maxxx_8-Dec-08 19:00 
GeneralRe: If I see one more... Pin
Roger Wright9-Dec-08 1:57
professionalRoger Wright9-Dec-08 1:57 
GeneralRe: If I see one more... Pin
Joe Woodbury9-Dec-08 6:44
professionalJoe Woodbury9-Dec-08 6:44 
GeneralRe: If I see one more... Pin
Rajesh R Subramanian8-Dec-08 19:53
professionalRajesh R Subramanian8-Dec-08 19:53 
GeneralRe: If I see one more... Pin
CPallini8-Dec-08 22:07
mveCPallini8-Dec-08 22:07 
GeneralRe: If I see one more... Pin
Roger Wright9-Dec-08 1:53
professionalRoger Wright9-Dec-08 1:53 
GeneralRe: If I see one more... Pin
Gary Wheeler9-Dec-08 1:09
MemberGary Wheeler9-Dec-08 1:09 
GeneralRe: If I see one more... Pin
Roger Wright9-Dec-08 2:15
professionalRoger Wright9-Dec-08 2:15 
GeneralRe: If I see one more... Pin
Gary Wheeler9-Dec-08 2:28
MemberGary Wheeler9-Dec-08 2:28 
GeneralRe: If I see one more... Pin
El Corazon8-Dec-08 20:02
MemberEl Corazon8-Dec-08 20:02 
JokeInternet Explorer WTF Pin
Nish Nishant8-Dec-08 16:06
sitebuilderNish Nishant8-Dec-08 16:06 
GeneralRe: Internet Explorer WTF Pin
Indivara8-Dec-08 16:12
professionalIndivara8-Dec-08 16:12 
GeneralRe: Internet Explorer WTF Pin
_Maxxx_8-Dec-08 16:17
professional_Maxxx_8-Dec-08 16:17 
GeneralRe: Internet Explorer WTF Pin
Roger Wright8-Dec-08 16:24
professionalRoger Wright8-Dec-08 16:24 
GeneralRe: Internet Explorer WTF Pin
Ashley van Gerven8-Dec-08 18:23
MemberAshley van Gerven8-Dec-08 18:23 
GeneralRe: Internet Explorer WTF Pin
Michael Dunn8-Dec-08 19:36
sitebuilderMichael Dunn8-Dec-08 19:36 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.