Skip to content

Commit

Permalink
define-method-combination: fix :documentation processing.
Browse files Browse the repository at this point in the history
Don't store (nil) if there's no :documentation.
  • Loading branch information
stassats committed May 11, 2018
1 parent 61770d6 commit 77fcd05
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions src/pcl/defcombin.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -89,13 +89,16 @@
(documentation (getf (cddr whole) :documentation canary))
(ioa (getf (cddr whole) :identity-with-one-argument nil))
(operator
(getf (cddr whole) :operator type-name)))
(unless (eql documentation canary)
(unless (stringp documentation)
(%program-error "~@<~S argument to the short form of ~S must be a string.~:>"
:documentation 'define-method-combination)))
(getf (cddr whole) :operator type-name)))
(unless (or (eq documentation canary)
(stringp documentation))
(%program-error "~@<~S argument to the short form of ~S must be a string.~:>"
:documentation 'define-method-combination))
`(load-short-defcombin
',type-name ',operator ',ioa ',documentation (sb-c:source-location))))
',type-name ',operator ',ioa
',(and (neq documentation canary)
documentation)
(sb-c:source-location))))

(defun load-short-defcombin (type-name operator ioa doc source-location)
(let ((info (make-method-combination-info
Expand Down

0 comments on commit 77fcd05

Please sign in to comment.