supportoranges
asked on
Reference going out of scope impact to actual object being referred to
In the following ex:
int myClass::getBeer(void)
{
MyBuddy& refBuddy=getABuddy(true);
refBuddy.getMoreBeer(1,2);
return 0;
}
when refBuddy goes out of scope will it delete the actual object referenced? I remember something horrible once happened along these lines and want to avoid a repeat performance.
int myClass::getBeer(void)
{
MyBuddy& refBuddy=getABuddy(true);
refBuddy.getMoreBeer(1,2);
return 0;
}
when refBuddy goes out of scope will it delete the actual object referenced? I remember something horrible once happened along these lines and want to avoid a repeat performance.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER