 
      (let ((palette (mapcar #',(intern (concat (symbol-name theme) "-theme-adjust")) ',(macroexpand palette))))
        (custom-theme-set-faces ',theme
-                               ,@(mapcar (lambda (def) `(backquote (,(car def) ,(mkspec (macroexpand palette) (cdr def))))) (macroexpand face-defs)))
+                               ,@(mapcar (lambda (def) `(backquote (,(car def) ,(hydrangea-mkspec (macroexpand palette) (cdr def))))) (macroexpand face-defs)))
        ,@body)
 
      (provide-theme ',theme)))

           `(,'\, (elt (elt palette ,found) ,(+ 1 i)))
         x)))
    ((pred listp)
     (mapcar (lambda (y) (eval-for palette i y)) x))
    (_ x)))

(defun mkspec (palette spec)
  `((((min-colors 65536)) ,@(eval-for palette 0 spec))
    (t                    ,@(eval-for palette 1 spec))))

(defmacro hydrangea-define-theme (theme doc palette face-defs &rest body)
  ""

(require 'cl-lib)
(require 'pcase)

(defun hydrangea-unwrap-unquote (x)
  (if (and (listp x) (eq (car x) '\,))
      (cadr x)
    x))

(defun hydrangea-eval-for (palette i x)
  (pcase x
    (`(lighten    ,percent ,color) `(,'\, (color-lighten-name    ,(hydrangea-unwrap-unquote (hydrangea-eval-for palette i color)) ,percent)))
    (`(darken     ,percent ,color) `(,'\, (color-darken-name     ,(hydrangea-unwrap-unquote (hydrangea-eval-for palette i color)) ,percent)))
    (`(saturate   ,percent ,color) `(,'\, (color-saturate-name   ,(hydrangea-unwrap-unquote (hydrangea-eval-for palette i color)) ,percent)))
    (`(desaturate ,percent ,color) `(,'\, (color-desaturate-name ,(hydrangea-unwrap-unquote (hydrangea-eval-for palette i color)) ,percent)))
    ((pred symbolp)
     (let ((j 0)
           (found nil))
