mirror of
https://github.com/dimitri/pgloader.git
synced 2026-01-26 09:31:02 +01:00
The metabang-bind lib offers a nice bind macro that solves the problem of ignoring bindings in destructuring-bind, and allows a let* approach to nested destructuring (wven when mixed with let declarations). Using that lib (that we already indirectly depend on anyway) simplifies the parser code substantially.
11 lines
246 B
Common Lisp
11 lines
246 B
Common Lisp
;;;
|
|
;;; Monkey patch metaband-bind macro to ignore nil:
|
|
;;;
|
|
;;; https://github.com/gwkkwg/metabang-bind/issues/9
|
|
;;;
|
|
|
|
(in-package #:metabang.bind)
|
|
|
|
(defun var-ignorable-p (var)
|
|
(and (symbolp var) (string= (symbol-name var) (symbol-name '_))))
|