aboutsummaryrefslogtreecommitdiff
path: root/src/propspec.lisp
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2021-03-18 09:31:43 -0700
committerSean Whitton <spwhitton@spwhitton.name>2021-03-18 09:55:57 -0700
commit9288d579cce868af02e442ad8d910c06b710ef53 (patch)
treee20d924c6c7be9ebe2b138c746438ffcc17cc485 /src/propspec.lisp
parent415ce75b066526125c5647e54b0db4821f4ddc54 (diff)
downloadconsfigurator-9288d579cce868af02e442ad8d910c06b710ef53.tar.gz
add OS:HOST-TYPECASE
Signed-off-by: Sean Whitton <spwhitton@spwhitton.name>
Diffstat (limited to 'src/propspec.lisp')
-rw-r--r--src/propspec.lisp24
1 files changed, 0 insertions, 24 deletions
diff --git a/src/propspec.lisp b/src/propspec.lisp
index 46de09f..335def7 100644
--- a/src/propspec.lisp
+++ b/src/propspec.lisp
@@ -330,27 +330,3 @@ apply the elements of REQUIREMENTS in reverse order."
:unapply (get psym 'apply)
:args args)))
-;; TODO should move this into property/os.lisp once we determine the API for
-;; property combinator helper macros
-(define-function-property-combinator os-typecase* (&rest cases)
- (flet ((choose-propapp ()
- (or (loop with host = (class-of (get-hostattrs-car :os))
- for (type propapp) on cases by #'cddr
- when (subtypep host type) return propapp)
- (inapplicable-property
- "Host's OS ~S fell through OS:TYPECASE."
- (class-of (get-hostattrs-car :os))))))
- (:retprop :type (collapse-types (loop for propapp in (cdr cases) by #'cddr
- collect (propapptype propapp)))
- :desc (lambda (&rest args)
- (declare (ignore args))
- (propappdesc (choose-propapp)))
- :check (lambda (&rest args)
- (declare (ignore args))
- (propappcheck (choose-propapp)))
- :apply (lambda (&rest args)
- (declare (ignore args))
- (propappapply (choose-propapp)))
- :unapply (lambda (&rest args)
- (declare (ignore args))
- (propappunapply (choose-propapp))))))