I am trying to understand something:
int x = 4;
int &val = x;
What is actually going on behind the scenes? Does val just become another name for the variable x at the same address? With no additional memory allocated?
Does x give an address to val implicitly? Is x automatically promoted to the same reference to int type as val?
Small stuff like this really catch me up =/
int x = 4;
int &val = x;
What is actually going on behind the scenes? Does val just become another name for the variable x at the same address? With no additional memory allocated?
Does x give an address to val implicitly? Is x automatically promoted to the same reference to int type as val?
Small stuff like this really catch me up =/