I have an instance of a Node class and I have:
So as far as I know myNode is pointing to someOtherNode not making a copy.Code:
Node myNode = someOtherNode;
I now need to set the "someOtherNode" to null but the only referance I have to it is myNode.
This should not effect "someOtherNode" from what I understand it will only destroy the pointer? Is this correct and if so is there a way to set what it is POINTING to, to null?Code:
myNode = null;
Somthing like how C uses:
I dont remember if thats the C syntax but the idea is that null will apply to whatever it is pointing at.Code:
nodePointer* = null;
Any tips? Thank you!