Hi Edi,
yes, it will be a problem to connect with the debugger after you have disabled the pins.
What I do is this: I wait some time after boot (say 2-5 seconds) until I disable the SWD pins. This gives me time after reset to connect to the board with the debugger.
I hope this helps,
Erich