Skip to content

Commit 928838c

Browse files
committed
Hint to inspection functions when only parts of a system is shown
1 parent e9e1297 commit 928838c

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/systems/abstractsystem.jl

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1912,7 +1912,7 @@ function Base.show(io::IO, mime::MIME"text/plain", sys::AbstractSystem; bold = t
19121912
end
19131913
end
19141914
limited = nrows < nsubs
1915-
limited && print(io, "\n") # too many variables to print
1915+
limited && print(io, "\n\n see ModelingToolkit.get_systems(sys) for all") # too many variables to print # TODO: should export e.g. systems(sys) for consistency
19161916

19171917
# Print equations
19181918
eqs = equations(sys)
@@ -1922,9 +1922,9 @@ function Base.show(io::IO, mime::MIME"text/plain", sys::AbstractSystem; bold = t
19221922
next = n_extra_equations(sys)
19231923
ntot = neqs + nobs + next
19241924
ntot > 0 && printstyled(io, "\nEquations ($ntot):"; bold)
1925-
neqs > 0 && printstyled(io, "\n $neqs solvable")
1926-
nobs > 0 && printstyled(io, "\n $nobs observed")
1927-
next > 0 && printstyled(io, "\n $next extra")
1925+
neqs > 0 && printstyled(io, "\n $neqs solvable … see equations(sys) for all")
1926+
nobs > 0 && printstyled(io, "\n $nobs observed … see observed(sys) for all")
1927+
next > 0 && printstyled(io, "\n $next extra") # TODO: what are these equations?
19281928
#Base.print_matrix(io, eqs) # usually too long and not useful to print all equations
19291929
end
19301930

@@ -1957,7 +1957,7 @@ function Base.show(io::IO, mime::MIME"text/plain", sys::AbstractSystem; bold = t
19571957
end
19581958
end
19591959
limited = nrows < nvars
1960-
limited && print(io, "\n") # too many variables to print
1960+
limited && printstyled(io, "\n\n see $(nameof(varfunc))(sys) for all") # too many variables to print
19611961
end
19621962

19631963
return nothing

0 commit comments

Comments
 (0)