* test/src/comp-tests.el (comp-tests-cl-macro-exp): New test.
* test/src/comp-test-funcs-dyn.el: Require `cl-lib'.
(comp-tests-cl-macro-exp-f): New function.
;;; Code:
+(require 'cl-lib)
+
(defun comp-tests-ffuncall-callee-dyn-f (a b)
(list a b))
(defun comp-tests-ffuncall-callee-opt-rest-dyn-f (a b &optional c &rest d)
(list a b c d))
+(defun comp-tests-cl-macro-exp-f ()
+ (cl-loop for xxx in '(a b)
+ for yyy = xxx
+ collect xxx))
+
(provide 'comp-test-dyn-funcs)
;;; comp-test-funcs-dyn.el ends here
(should (equal '(2 . many)
(func-arity #'comp-tests-ffuncall-callee-opt-rest-dyn-f))))
+(ert-deftest comp-tests-cl-macro-exp ()
+ "Verify CL macro expansion (bug#42088)."
+ (should (equal (comp-tests-cl-macro-exp-f) '(a b))))
+
;;; comp-tests.el ends here