Fork me on GitHub

random thought, if there was a wrapper around a C STM system, eg , could one implement clojure like concurrency primitives and load them as dynamic modules ?


I don't see why not


asked on irc, general consensus is that STM isn’t that beneficial without accompanying immutable data structures


hey, question. I'm doing this so that a plugin that expects a single symbol actually picks one from a random list, it seems to work but was wondering if this is the proper way. I basically want a function to be evaluated where a variable is expected.

(defun pick-random (list)
    (nth (random (length list)) list))

  (use-package circadian
    :ensure t
    (let ((dark-themes '(spacemacs-dark material-dark sanityinc-tomorrow-eighties))
          (light-themes '(spacemacs-light material-light gandalf sanityinc-tomorrow-day otmos-softer soft-morning)))
      (setq circadian-themes `(("8:00" . ,(pick-random light-themes))
                               ("19:00" . ,(pick-random dark-themes))))


can you paste a failed attempt?


this seems to work, though i'm pretty sure it doesn't evaluate each time since it evaluates only once at startup


Ah, I got you now. I don't think want a function to be evaluated where a variable is expected is feasible. You'd have to open a PR against circadian to make things more dynamic


I figured, I thought elisp had some magic hybrid function/variable