aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2021-03-05 10:44:02 -0700
committerSean Whitton <spwhitton@spwhitton.name>2021-03-05 12:20:14 -0700
commit21d9e808eeb94b6bb4394a25ad6a0d37c180ccff (patch)
treec08884ebf6be5edc807f9c7610159781d82cbb8e /src
parent0478ad0c38d479b978d1a787cbcc090fab38a324 (diff)
downloadconsfigurator-21d9e808eeb94b6bb4394a25ad6a0d37c180ccff.tar.gz
define INAPPLICABLE-PROPERTY
Signed-off-by: Sean Whitton <spwhitton@spwhitton.name>
Diffstat (limited to 'src')
-rw-r--r--src/package.lisp1
-rw-r--r--src/property.lisp5
2 files changed, 6 insertions, 0 deletions
diff --git a/src/package.lisp b/src/package.lisp
index 96fbf94..5869986 100644
--- a/src/package.lisp
+++ b/src/package.lisp
@@ -85,6 +85,7 @@
#:propunapply
#:defprop
#:defproplist
+ #:inapplicable-property
#:get-hostattrs
#:push-hostattrs
#:get-hostname
diff --git a/src/property.lisp b/src/property.lisp
index 9035452..0f922fe 100644
--- a/src/property.lisp
+++ b/src/property.lisp
@@ -162,6 +162,11 @@ subroutines at the right time."
;;;; hostattrs in property subroutines
+(define-condition inapplicable-property (error)
+ ((text :initarg :text :reader inapplicable-property-text))
+ (:report (lambda (condition stream)
+ (format stream "~A" (inapplicable-property-text condition)))))
+
(defun get-hostattrs (k)
"Retrieve the list of static informational attributes of type KEY.