Hold down the Option key when erasing using the Eraser Brush, and you’ll get a marquee that you can drag to erase a perfectly rectangular area.
Bonus Eraser Tool tip: edit the keyboard shortcuts so the Eraser uses the “E” key, and remap the Free Transform tool to Shift-E (essentially swapping the keyboard shortcuts for the two tools). Seems much more intuitive this way.
Both tips via FreeTransform