Mail von Nicolas Goaziou, Sun, 04 Jun 2017 at 10:24:57 +0200: Hello,
> "Stefan-W. Hahn" <stefan.h...@s-hahn.de> writes: > > > I looked at it, but sorry, I think this also is not right, it expands to: > > > > Both looking wrong for me. Sorry. > > What do you think is wrong? > > In particular > > (let (res) > (dolist (pair (buffer-local-variables)) > (pcase pair > (`(,var . ,val) > (push (list 'set var val) res)))) > res) > > expands to > > ((set flyspell-word-cache-result _) > (set flyspell-word-cache-end -1) > (set undo-auto--last-boundary-cause (2 #<buffer *scratch*>)) > (set syntax-ppss-last (1 0 nil nil nil nil nil 0 nil nil nil)) > (set syntax-propertize--done 139) > (set flyspell-changes nil) > (set deactivate-mark nil) > (set flyspell-pre-point 139) > (set auto-revert-notify-modified-p nil) > ... > ) > > which looks correct. Obviously you are right, I get the ame result when evaluating it. What I don't understand is, if I expand the pcase with (macrostep-expand) I get the following: ,---- | (let (res) | (dolist (pair (buffer-local-variables)) | (if | (consp pair) | (let* | ((x | (car pair)) | (x | (cdr pair))) | (let | ((val x) | (var x)) | (push | (list 'set var val) | res))) | nil)) | res) `---- And this is obviously wrong. With kind regards, Stefan -- Stefan-W. Hahn It is easy to make things. It is hard to make things simple.