Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Lukas <[email protected]>
  • Loading branch information
Jutho and lkdvos authored Jan 4, 2024
1 parent fff1008 commit 00d1d23
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 0 additions & 2 deletions src/planar/planaroperations.jl
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ function planarcontract!(C::AbstractTensorMap{S,N₁,N₂},
codB, domB = codomainind(B), domainind(B)
oindA, cindA = pA
cindB, oindB = pB
# @show codA, domA, codB, domB, oindA, cindA, oindB, cindB, pAB
oindA, cindA, oindB, cindB = reorder_indices(codA, domA, codB, domB, oindA, cindA,
oindB, cindB, pAB...)

Expand Down Expand Up @@ -92,7 +91,6 @@ _cyclicpermute(t::Tuple{}) = ()
function reorder_indices(codA, domA, codB, domB, oindA, oindB, p1, p2)
N₁ = length(oindA)
N₂ = length(oindB)
# @show codA, domA, codB, domB, oindA, oindB, p1, p2
@assert length(p1) == N₁ && all(in(p1), 1:N₁)
@assert length(p2) == N₂ && all(in(p2), N₁ .+ (1:N₂))
oindA2 = TupleTools.getindices(oindA, p1)
Expand Down
2 changes: 1 addition & 1 deletion src/planar/preprocessors.jl
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ function _remove_braidingtensors!(ex, indexmap) # ex is guaranteed to be a singl
newarg, unchanged = _remove_braidingtensors!(ex.args[3], indexmap)
return Expr(:call, :\, ex.args[2], newarg), unchanged
else
error("unexpected expression $ex")
throw(ArgumentError("unexpected expression $ex"))
end
end

Expand Down

0 comments on commit 00d1d23

Please sign in to comment.