I have one class a and I am deriving class b from a and i have one pointer to b .
I have one function which i will be calling and in turn it will change the address of base class in the same time it should not change class b.
Can anyone give a solution to this.