问题 Suppose you define a new composite type in Julia and a variable of that type: type MyType α::Int64 β::Vector{Float64} γ::Float64 MyType(α::Int64, β::Vector{Float64}, γ::Float64) = new(α, β, γ) end mt = MyType(5, [1.2, 4.1, 2], 0.2) Now if you are in REPL mode, you can simply check the value of mt by typing mt and pressing Enter: mt MyType(5,[1.2,4.1,2.0],0.2) If I want to customize the way variables of MyType are displayed, I can define a function and use it like customized_display(mt) :