Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
A
asdf
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jan Moringen
asdf
Commits
c8487c61
Commit
c8487c61
authored
11 years ago
by
Francois-Rene Rideau
Browse files
Options
Downloads
Patches
Plain Diff
Update debug.lisp: uiop vs asdf/driver, ability to load slime afterwards, etc.
parent
a3dace27
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
uiop/contrib/debug.lisp
+10
-14
10 additions, 14 deletions
uiop/contrib/debug.lisp
with
10 additions
and
14 deletions
uiop/contrib/debug.lisp
+
10
−
14
View file @
c8487c61
...
...
@@ -11,21 +11,21 @@
#|
;;; If ASDF is already loaded,
;;; you can load these utilities in the current package as follows:
(
d:asdf
-debug)
;; which i
f you left the :D nickname to asdf/driver is short for
:
(
asdf
/utility:
:asdf
-debug)
(
uiop:uiop
-debug)
;; which i
s the same as
:
(
uiop
/utility:
uiop
-debug)
;; The above macro can be configured to load any other debugging utility
;; that you may prefer to this one, with your customizations,
;; by setting the variable
;;
asdf-
utility:*
asdf
-debug-utility*
;;
uiop/
utility:*
uiop
-debug-utility*
;; to a form that evaluates to a designator of the pathname to your file.
;; For instance, on a home directory shared via NFS with different names
;; on different machines, with your debug file in ~/lisp/debug-utils.lisp
;; you could in your ~/.sbclrc have the following configuration setting:
(require :asdf)
(setf
asdf
/utility:*
asdf
-debug-utility*
'(
asdf
/pathname:subpathname (
asdf
/os:user-homedir) "lisp/debug-utils.lisp"))
(setf
uiop
/utility:*
uiop
-debug-utility*
'(
uiop
/pathname:subpathname (
uiop
/os:user-homedir) "lisp/debug-utils.lisp"))
;;; If ASDF is not loaded (for instance, when debugging ASDF itself),
;;; Try the below, fixing the pathname to point to this file:
...
...
@@ -102,21 +102,17 @@ The macro expansion has relatively low overhead in space of time."
;;; Quick definitions for use at the REPL
(
defun
w
(
&rest
x
)
(
format
t
"~&~{~S~^ ~}~%"
x
))
;Write, space separated + LF
(
defun
a
(
&rest
x
)
(
format
t
"~&~{~A~}~%"
x
))
;print Anything, no separator, LF
(
defun
e
(
x
)
(
cons
x
(
ignore-errors
(
list
(
eval
x
)))))
;
eV
aluate
(
defun
e
(
x
)
(
cons
x
(
ignore-errors
(
list
(
eval
x
)))))
;
Ev
aluate
(
defmacro
x
(
x
)
`
(
format
t
"~&~S => ~S~%"
',x
,
x
))
;eXamine
(
defun
i
(
&rest
x
)
(
apply
(
read-from-string
"swank:inspect-in-emacs"
)
x
))
; SLIME inspection
(
defun
ra
(
&rest
x
)
(
require
:cl-ppcre
)
(
apply
(
read-from-string
"cl-ppcre:regex-apropos"
)
x
))
(
defmacro
!a
(
&rest
foo
)
; define! Alias
`
(
progn
,@
(
loop
:for
(
alias
name
)
:on
foo
:by
#'
cddr
:collect
(
if
(
macro-function
name
)
`
(
defmacro
,
alias
(
&rest
x
)
`
(
,
',name
,@
x
))
`
(
defun
,
alias
(
&rest
x
)
(
apply
',name
x
))))))
;;; common aliases
(
!a
(
!a
;;; common aliases
d
describe
ap
apropos
!p
defparameter
m1
macroexpand-1
)
;;; SLIME integration
(
when
(
find-package
:swank
)
(
eval
(
read-from-string
"(!a i swank:inspect-in-emacs)"
)))
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment