Hi,
It is incorrect to connect 3.3V to a GPIO pin directly which is configured as GPIO, the case should be avoided.
If you do need to connect a 3.3V to a GPIO output pin, you can connect a serial resistor, for example, the maximum output pin source/sink current is 4mA, so you can connect at least 3.3V/4mA=0.825K ohm resistor, so you can connect 1K or above serial resistor between the GPIO pin and 3.3V.
Secondly, you can configure the GPIO pin in open drain mode, connect the GPIO output pin to 3.3V via a pull-up resistor.
Anyway, it is not recommended to connect 3.3V to GPIO pin directly without any load, which can damage the I/O cell.
Hope it can help you
BR
XiangJun Rong