A textbook approach, attributed to Charlie Bennett, for creating reversible circuit which outputs the input qubits and the initialized ancilla qubits involves copying the function output between the two blocks - the forward and the reverse function. As can be seen in this figure
My question is, aren't the copied function qubits entangled to the internal qubits which are being zeroed by the reverse circuit?
Does this trick only work when the function output qubits are in the eigenstates (either |0⟩ or |1⟩)?