Spent several hours today trying to figure out why my #elisp code was misbehaving. Turns out, I made a mistake while trying to be clever. Instead of doing:

(when (and cond1 cond2)
  stuff
  ...)

I did:
(and cond1 cond2
  stuff
  ...)

...which would only work if every instruction in stuff returned a on-nil value.

I should stop trying to be clever.

#emacs

Edit: when, not while

This website uses cookies. If you continue browsing this website, you agree to the usage of cookies.