diff options
author | Philipp Stephani <phst@google.com> | 2020-08-02 22:07:27 +0200 |
---|---|---|
committer | Philipp Stephani <phst@google.com> | 2020-08-02 22:07:27 +0200 |
commit | a325584281c4d8552917fcb97caed449acb7ee65 (patch) | |
tree | 46f45e805c88b29b963ab83117fc7abf8be66f57 /test/lisp/emacs-lisp/cl-generic-tests.el | |
parent | 2ad38b4745bf0203ca9ca0fe2eeb376943d384c6 (diff) | |
download | emacs-a325584281c4d8552917fcb97caed449acb7ee65.tar.gz |
Improve Edebug symbols for inlined secondary methods (Bug#42671)
* lisp/emacs-lisp/cl-generic.el (cl-defgeneric): Include qualifiers in
Edebug symbol name.
* test/lisp/emacs-lisp/cl-generic-tests.el
(cl-defgeneric/edebug/method): Adapt unit test.
Diffstat (limited to 'test/lisp/emacs-lisp/cl-generic-tests.el')
-rw-r--r-- | test/lisp/emacs-lisp/cl-generic-tests.el | 28 |
1 files changed, 15 insertions, 13 deletions
diff --git a/test/lisp/emacs-lisp/cl-generic-tests.el b/test/lisp/emacs-lisp/cl-generic-tests.el index fc39e349523..5aa58782f36 100644 --- a/test/lisp/emacs-lisp/cl-generic-tests.el +++ b/test/lisp/emacs-lisp/cl-generic-tests.el @@ -256,7 +256,8 @@ Edebug symbols (Bug#42672)." (with-temp-buffer (dolist (form '((cl-defgeneric cl-defgeneric/edebug/method/1 (_) (:method ((_ number)) 1) - (:method ((_ string)) 2)) + (:method ((_ string)) 2) + (:method :around ((_ number)) 3)) (cl-defgeneric cl-defgeneric/edebug/method/2 (_) (:method ((_ number)) 3)))) (print form (current-buffer))) @@ -272,18 +273,19 @@ Edebug symbols (Bug#42672)." ;; Make generated symbols reproducible. (gensym-counter 10000)) (eval-buffer) - (should (equal (reverse instrumented-names) - ;; The generic function definitions come after - ;; the method definitions because their body ends - ;; later. - ;; FIXME: We'd rather have names such as - ;; `cl-defgeneric/edebug/method/1 ((_ number))', - ;; but that requires further changes to Edebug. - (list (intern "cl-generic-:method@10000 ((_ number))") - (intern "cl-generic-:method@10001 ((_ string))") - 'cl-defgeneric/edebug/method/1 - (intern "cl-generic-:method@10002 ((_ number))") - 'cl-defgeneric/edebug/method/2)))))) + (should (equal + (reverse instrumented-names) + ;; The generic function definitions come after the + ;; method definitions because their body ends later. + ;; FIXME: We'd rather have names such as + ;; `cl-defgeneric/edebug/method/1 ((_ number))', but + ;; that requires further changes to Edebug. + (list (intern "cl-generic-:method@10000 ((_ number))") + (intern "cl-generic-:method@10001 ((_ string))") + (intern "cl-generic-:method@10002 :around ((_ number))") + 'cl-defgeneric/edebug/method/1 + (intern "cl-generic-:method@10003 ((_ number))") + 'cl-defgeneric/edebug/method/2)))))) (provide 'cl-generic-tests) ;;; cl-generic-tests.el ends here |