Yes, it is legal.
I could officially prove this only by citing most of the standard C ++ text.
You pass two links, both of which refer to the same object, which is great. Then you assign new values ββto this single object. Also great.
source share