Say you have these two branches -
*p1
p2
Now you did some file changes on p1 and you want to checkout to p2.
But git didn't allow you to do that.
What is that situation where git doesn't allow you to checkout?
Actually, I faced this issue once but I am not able to remember that situation and now I am confused because now, git is allowing to checkout to another branch after doing some file changes.
Could you please provide a situation where git isn't allowing to do that?