I borrowed a FSM.
The block diagrams for the antilock brake system show the TCC brake switch and Cruise/shift interlock brake switch wired into the EBTCM. Electronic Brake and Traction Control Module.
My current guess is that previous owner, or flawed accident repair, rendered your brake interlock inoperable. That is, if you can shift out of park wile NOT with your foot on the brake, somebody or something messed up your interlock switch and you need to fix it. The cruise switch closes when you step on brake. When it is closed it disengages the cruise control and allows the car to be shifted out of park. Some people do not like that. Problem is the same switch also when open permits the cruise control to engage. If it is closed cruise will not engage and the EBTCM thinks you are applying brakes so it will kick you out of TCC lockup.
So it could be as simple as a switch gone bad or someone defeated the switch because they did not want to step on the brake to shift out of park. It needs to be restored to factory configuration for the EBTCM (and in turn the transmission) to act right.