Skip to content

Instantly share code, notes, and snippets.

@davazp
Created May 5, 2013 23:32
Show Gist options
  • Save davazp/5522582 to your computer and use it in GitHub Desktop.
Save davazp/5522582 to your computer and use it in GitHub Desktop.
JSCL destructuring-bind macroexpansion
(destructuring-bind ((var count &optional result) &body body)
list
nil)
;; =>
(LET* ((#:G19046 (VALIDATE-REQVARS LIST 1))
(#:G19047 (VALIDATE-REQVARS (CAR #:G19046) 2))
(VAR (CAR #:G19047))
(COUNT (CAR (CDR #:G19047)))
(RESULT
(IF (NULL (CDR (CDR #:G19047)))
NIL
(CAR (CDR (CDR #:G19047)))))
(#:G19048 (VALIDATE-MAX-ARGS (CDR (CDR (CDR #:G19047)))))
(BODY (CDR #:G19046)))
NIL)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment