I haven’t been writing much lately because I’ve been in the process of switching my life over to Linux from OS X. I finally managed to get my blog infrastructure running again, so let’s take a look at some deceptively-tricky Common Lisp macros: when-let and if-let (and their let* counterparts).
Introduction I first heard of the when-let and if-let macros when I learned Clojure a few years ago. They’re used like let to bind values to variables, but if a value is nil then when-let will return nil without running the body, and if-let will execute its alternative branch.
Published on July 09, 2018 09:00