View Full Version : references in C++ - it's location

01-29-2005, 11:38 PM
Hi all,

I've read that a reference is an ALIAS and not a pointer. ie it represents
another variable name for the same object.
Using the ' &Reference' returns the address of the target ,not the
reference. So...how Do I find the address of the reference?
Is it a hidden compiler variable which does not get put into the assembly?
My guess is that the compiler treats the reference and it's target as the same variable and puts it in the exact same position in the final exe.
If thats the case then what happens when the reference is
passed to a function ?
Thanks for any insight.