X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcode%2Fshow.lisp;h=7ba55016ada4f9dfa99672f4a1db87ef0e335e19;hb=a37de74b393a808825585000bb5b2b92218d46c0;hp=9359e5429577004f93b9ab11ac08851a1870d56f;hpb=cbaa1997bb097a55d108df592ac3b7eb4a703fff;p=sbcl.git diff --git a/src/code/show.lisp b/src/code/show.lisp index 9359e54..7ba5501 100644 --- a/src/code/show.lisp +++ b/src/code/show.lisp @@ -13,6 +13,21 @@ (in-package "SB!INT") ;;;; various SB-SHOW-dependent forms +;;;; +;;;; In general, macros named /FOO +;;;; * are for debugging/tracing +;;;; * expand into nothing unless :SB-SHOW is in the target +;;;; features list +;;;; Often, they also do nothing at runtime if */SHOW* is NIL, but +;;;; this is not always true for some very-low-level ones. +;;;; +;;;; (I follow the "/FOO for debugging/tracing expressions" naming +;;;; rule and several other naming conventions in all my Lisp +;;;; programming when possible, and then set Emacs to display comments +;;;; in one shade of blue, tracing expressions in another shade of +;;;; blue, and declarations and assertions in a yellowish shade, so +;;;; that it's easy to separate them from the "real code" which +;;;; actually does the work of the program. -- WHN 2001-05-07) ;;; Set this to NIL to suppress output from /SHOW-related forms. #!+sb-show (defvar */show* t) @@ -70,7 +85,8 @@ ;;; a disabled-at-compile-time /SHOW, implemented as a macro instead ;;; of a function so that leaving occasionally-useful /SHOWs in place ;;; but disabled incurs no run-time overhead and works even when the -;;; arguments can't be evaluated due to code flux +;;; arguments can't be evaluated (e.g. because they're only meaningful +;;; in a debugging version of the system, or just due to bit rot..) (defmacro /noshow (&rest rest) (declare (ignore rest))) @@ -112,9 +128,6 @@ #+sb-xc-host `(/show "(/primitive-print)" ,thing) #-sb-xc-host `(sb!sys:%primitive print (the simple-string ,thing)))) -(defmacro /nohexstr (thing) - (declare (ignore thing))) - ;;; low-level display of a system word, works even early in cold init (defmacro /hexstr (thing) (declare (ignorable thing)) ; (for when #!-SB-SHOW)