Hidden bindings don't print with info command.

This commit is contained in:
Erik Svedäng 2018-03-27 14:21:12 +02:00
parent c1e427688d
commit 570ae954e2
2 changed files with 3 additions and 3 deletions

View File

@ -17,8 +17,8 @@
(list 'macro-log (list 'meta name "sig")))
(doc hide "Mark a binding as hidden, this will make it not print with the 'info' command.")
(defmacro hide [name]
(list 'meta-set! name "hide" true))
(defmacro hidden [name]
(list 'meta-set! name "hidden" true))
(doc private "Mark a binding as private, this will make it inaccessible from other modules.")
(defmacro private [name]

View File

@ -367,7 +367,7 @@ prettyEnvironment = prettyEnvironmentIndented 0
prettyEnvironmentIndented :: Int -> Env -> String
prettyEnvironmentIndented indent env =
joinWith "\n" $ map (showBinderIndented indent) (Map.toList (envBindings env)) ++
joinWith "\n" $ filter (/= "") (map (showBinderIndented indent) (Map.toList (envBindings env))) ++
let modules = envUseModules env
in if null modules
then []