Skip to content

Commit 4cb75a3

Browse files
committed
fix show for Make
1 parent 1146ac5 commit 4cb75a3

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

src/distributions.jl

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,15 @@ _deduce_type(::Type{T}, ::Val{false}, ::Type{X}) where {T,X} = T{X}
8282

8383
# show(::Make)
8484

85-
Base.show(io::IO, m::Make{T}) where {T} = print(io, typeof(m).name, "{", T, "}", m.x)
85+
function Base.show(io::IO, m::Make{T}) where {T}
86+
M = typeof(m)
87+
P = M.parameters[2].parameters
88+
t = ntuple(length(m.x)) do i
89+
P[i] isa Type{<:Type} ? P[i].parameters[1] : m.x[i]
90+
end
91+
Base.show_type_name(io, M.name)
92+
print(io, "{", T, "}", t)
93+
end
8694

8795

8896
## Uniform

0 commit comments

Comments
 (0)