From 248ceda3c49bc82805b56a4f440cb48460e3eb74 Mon Sep 17 00:00:00 2001 From: Lilith Orion Hafner Date: Sat, 27 May 2023 08:39:33 -0500 Subject: [PATCH] Abbreviate varinfo signature and re-order for consistency (#48860) --- stdlib/InteractiveUtils/src/InteractiveUtils.jl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stdlib/InteractiveUtils/src/InteractiveUtils.jl b/stdlib/InteractiveUtils/src/InteractiveUtils.jl index 5fbe19ac4efce..25f06250c3f8f 100644 --- a/stdlib/InteractiveUtils/src/InteractiveUtils.jl +++ b/stdlib/InteractiveUtils/src/InteractiveUtils.jl @@ -21,7 +21,7 @@ include("macros.jl") include("clipboard.jl") """ - varinfo(m::Module=Main, pattern::Regex=r""; all::Bool = false, imported::Bool = false, recursive::Bool = false, sortby::Symbol = :name, minsize::Int = 0) + varinfo(m::Module=Main, pattern::Regex=r""; all=false, imported=false, recursive=false, sortby::Symbol=:name, minsize::Int=0) Return a markdown table giving information about exported global variables in a module, optionally restricted to those matching `pattern`. @@ -37,7 +37,7 @@ The memory consumption estimate is an approximate lower bound on the size of the The output of `varinfo` is intended for display purposes only. See also [`names`](@ref) to get an array of symbols defined in a module, which is suitable for more general manipulations. """ -function varinfo(m::Module=Base.active_module(), pattern::Regex=r""; all::Bool = false, imported::Bool = false, sortby::Symbol = :name, recursive::Bool = false, minsize::Int=0) +function varinfo(m::Module=Base.active_module(), pattern::Regex=r""; all::Bool = false, imported::Bool = false, recursive::Bool = false, sortby::Symbol = :name, minsize::Int=0) sortby in (:name, :size, :summary) || throw(ArgumentError("Unrecognized `sortby` value `:$sortby`. Possible options are `:name`, `:size`, and `:summary`")) rows = Vector{Any}[] workqueue = [(m, ""),]