Skip to content

Commit

Permalink
Update src/ProtocolZoo/swapping.jl
Browse files Browse the repository at this point in the history
Co-authored-by: Lars Göttgens <[email protected]>
  • Loading branch information
Krastanov and lgoettgens authored Sep 14, 2024
1 parent a8331f1 commit a1e7672
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ProtocolZoo/swapping.jl
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ end
continue
end
# The compiler is not smart enough to figure out that qubit_pair_ is not nothing, so we need to tell it explicitly. A new variable name is needed due to @resumable.
qubit_pair = qubit_pair_::NTuple{2, Base.NamedTuple{(:slot, :id, :tag), Base.Tuple{RegRef, Int128, Tag}}}
qubit_pair = qubit_pair_::NTuple{2, Base.NamedTuple{(:slot, :id, :tag), Base.Tuple{RegRef, Int128, Tag}}} # TODO: replace by `NTuple{2, @NamedTuple{slot::RegRef, id::Int128, tag::Tag}}` once https://github.com/JuliaDynamics/ResumableFunctions.jl/issues/104 is resolved

(q1, id1, tag1) = qubit_pair[1].slot, qubit_pair[1].id, qubit_pair[1].tag
(q2, id2, tag2) = qubit_pair[2].slot, qubit_pair[2].id, qubit_pair[2].tag
Expand Down

0 comments on commit a1e7672

Please sign in to comment.