Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Compiler note undefined type #46

Merged
merged 1 commit into from
May 8, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions src/locatives/base.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,18 @@
calling 40ANTS-DOC/REFERENCE-API:CANONICAL-REFERENCE on it will return the same reference.
For extension only, don't call this directly."))

(define-condition locate-error (error)
((message :initarg :message :reader locate-error-message)
(object :initarg :object :reader locate-error-object)
(locative :initarg :locative :reader locate-error-locative))
(:documentation "Signaled by LOCATE when the lookup fails and ERRORP
is true.")
(:report (lambda (condition stream)
(format stream "~@<Could not locate ~A ~A.~@[ ~A~]~:@>"
(locate-error-locative condition)
(locate-error-object condition)
(locate-error-message condition)))))

(defun locate-error (&rest format-and-args)
"Call this function to signal a LOCATE-ERROR condition from a
LOCATE-OBJECT generic-function. FORMAT-AND-ARGS contains a format string and
Expand Down Expand Up @@ -84,18 +96,6 @@
(error 'locate-error :message (locate-error-message e)
:object object :locative locative)))))

(define-condition locate-error (error)
((message :initarg :message :reader locate-error-message)
(object :initarg :object :reader locate-error-object)
(locative :initarg :locative :reader locate-error-locative))
(:documentation "Signaled by LOCATE when the lookup fails and ERRORP
is true.")
(:report (lambda (condition stream)
(format stream "~@<Could not locate ~A ~A.~@[ ~A~]~:@>"
(locate-error-locative condition)
(locate-error-object condition)
(locate-error-message condition)))))


(defgeneric locate-and-find-source (object locative-type locative-args)
(:documentation
Expand Down