@@ -318,8 +318,8 @@ Return a view into the data of `t` corresponding to the splitting - fusion tree
318318`(f₁, f₂)`. In particular, this is an `AbstractArray{T}` with `T = scalartype(t)`, of size
319319`(dims(codomain(t), f₁.uncoupled)..., dims(codomain(t), f₂.uncoupled)...)`.
320320
321- Whenever `FusionStyle(sectortype(t))` , it is also possible to provide only the external
322- `sectors`, in which case the fusion tree pair will be constructed automatically.
321+ Whenever `FusionStyle(sectortype(t)) isa UniqueFusion` , it is also possible to provide only
322+ the external `sectors`, in which case the fusion tree pair will be constructed automatically.
323323"""
324324
325325@doc """
@@ -651,11 +651,15 @@ end
651651
652652# Show and friends
653653# ----------------
654- Base. dims2string (V:: HomSpace ) = join (dim .(codomain (V)), ' ×' ) * " ←" * join (dim .(domain (V)), ' ×' )
655654
656- Base. summary (io:: IO , t:: AbstractTensorMap ) = tensor_summary (io, t, space (t))
655+ function Base. dims2string (V:: HomSpace )
656+ str_cod = numout (V) == 0 ? " ()" : join (dim .(codomain (V)), ' ×' )
657+ str_dom = numin (V) == 0 ? " ()" : join (dim .(domain (V)), ' ×' )
658+ return str_cod * " ←" * str_dom
659+ end
657660
658- function tensor_summary (io:: IO , t, V)
661+ function Base. summary (io:: IO , t:: AbstractTensorMap )
662+ V = space (t)
659663 print (io, Base. dims2string (V), " " )
660664 Base. showarg (io, t, true )
661665 return nothing
@@ -669,7 +673,8 @@ function Base.show(io::IO, ::MIME"text/plain", t::AbstractTensorMap)
669673
670674 # 2) show spaces
671675 # println(io, " space(t):")
672- print (io, " " , space (t))
676+ println (io, " codomain: " , codomain (t))
677+ println (io, " domain: " , domain (t))
673678
674679 # 3) [optional]: show data
675680 get (io, :compact , true ) && return nothing
0 commit comments