Passing variables to functions
Posted
by Faken
on Stack Overflow
See other posts from Stack Overflow
or by Faken
Published on 2010-06-03T20:40:18Z
Indexed on
2010/06/03
20:44 UTC
Read the original article
Hit count: 353
A quick question:
When i pass a variable to a function, dose the program make a copy of that variable to use in the function? If it dose and I knew that the function would only read the variable and never write to it, is it possible to pass a variable to the function without creating a copy of that variable or should I just leave that up to the compiler optimizations to do that automatically for me?
© Stack Overflow or respective owner