Hello,
Thank you for reporting this. HRESULT E_FAIL during rename seems like a bug. May I ask what VS version and PHP Tools version do you have?
If that happens deterministically, may I ask you to replicate that and send us feedback from VS, it should contain information that might help us diagnose the issue. (https://docs.devsense.com/en/vs/troubleshooting/feedback)
Most frequent cause of debugging not working as expected is a configuration problem. Did you check https://docs.devsense.com/en/vs/debugging/troubleshooting ?
Please let me know.
Thank you!