summaryrefslogtreecommitdiff
path: root/test/lisp/kmacro-tests.el
Commit message (Collapse)AuthorAge
* Fix insertion of keyboard macro containing named keysRobert Pluim2023-02-24
| | | | | | | | | | | | | * lisp/kmacro.el: Autoload `macro--string-to-vector'. (kmacro-ring-head): Convert `last-kbd-macro' to a vector if it's a string, since `kmacro' uses `key-parse' on it. (kmacro-lambda-form): Remove require for 'macros * test/lisp/kmacro-tests.el (kmacro-tests-name-last-macro-key-parse-syntax): Test that insertion of macros that contain strings that look like named keys works correctly. (Bug#61700)
* ; Add 2023 to copyright years.Eli Zaretskii2023-01-01
|
* kmacro: Represent it as an OClosureStefan Monnier2022-04-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge the old lambda+list into a single OClosure object which plays both roles at the same time. Take advantage of it to provide a `cl-print-object` method so kmacro objects print nicely using the `key-parse` syntax. Also replace the old `kmacro-lambda-form` with a new `kmacro` constructor which takes a `key-parse` syntax, so that the code inserted with `insert-kbd-macro` is now more readable. * lisp/kmacro.el (kmacro): New OClosure type. (kmacro-ring-head): Use `kmacro` constructor. (kmacro-push-ring): Convert `elt` from old representation if needed. (kmacro-split-ring-element, kmacro-view-ring-2nd, kmacro-view-macro): Adapt to new representation. (kmacro-exec-ring-item): Turn into obsolete alias. (kmacro-call-ring-2nd, kmacro-end-or-call-macro): Adjust accordingly. (kmacro-start-macro): Simplify call to `kmacro-push-ring`. (kmacro): New constructor function. Replaces `kmacro-lambda-form`. (kmacro-lambda-form): Use it and declare obsolete. (kmacro-extract-lambda): Rewrite and declare obsolete. (kmacro-p): Rewrite. (cl-print-object): New method. (kmacro-bind-to-key, kmacro-name-last-macro): Simplify. * lisp/macros.el (macro--string-to-vector): New function. (insert-kbd-macro): Use it. Generate code using the `kmacro` constructor. * test/lisp/kmacro-tests.el (kmacro-tests-kmacro-bind-to-single-key): Silence warning. (kmacro-tests-name-last-macro-bind-and-rebind): Strengthen the test a bit. (kmacro-tests--cl-print): New test.
* Merge from origin/emacs-28Eli Zaretskii2022-01-01
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 836be7a112 ; * etc/refcards/ru-refcard.tex: Update Copyright year. 86cbc6ee4a * lisp/net/tramp-sh.el: Adapt copyright year ebe8772f65 ; Minor fixes related to copyright years 23c1ee6989 ; * test/manual/etags/ETAGS.good_N: Adjust to copyright ye... 8d3fc7ec89 * src/xfaces.c (face_for_font): Make 'hash' be uintptr_t. 19dcb237b5 ; Add 2022 to copyright years. # Conflicts: # etc/NEWS # etc/refcards/ru-refcard.tex # lib/cdefs.h # lisp/erc/erc-dcc.el # lisp/erc/erc-imenu.el # lisp/erc/erc-replace.el # lisp/image-dired.el # lisp/progmodes/xref.el # m4/alloca.m4 # m4/byteswap.m4 # m4/errno_h.m4 # m4/getopt.m4 # m4/gnulib-common.m4 # m4/inttypes.m4 # m4/stddef_h.m4 # m4/stdint.m4 # m4/sys_socket_h.m4
| * ; Add 2022 to copyright years.Eli Zaretskii2022-01-01
| |
* | Use defvar-keymap in testsStefan Kangas2021-12-26
|/ | | | | | | | | | | | * test/lisp/button-tests.el (button-tests--map): * test/lisp/emacs-lisp/edebug-tests.el (edebug-tests-keymap): * test/lisp/help-tests.el (help-tests-remap-map) (help-tests-major-mode-map, help-tests-minor-mode-map): * test/lisp/kmacro-tests.el (kmacro-tests-keymap): * test/lisp/repeat-tests.el (repeat-tests-map) (repeat-tests-repeat-map): * test/src/keymap-tests.el (keymap-tests-minor-mode-map) (keymap-tests-major-mode-map): Use defvar-keymap.
* ; Minor stylistic checkdoc fixes in test/**/*.elStefan Kangas2021-09-26
|
* ; Fix typos in doc stringsMattias EngdegÄrd2021-03-12
|
* Update copyright year to 2021Paul Eggert2021-01-01
| | | | Run "TZ=UTC0 admin/update-copyright".
* Update copyright year to 2020Paul Eggert2020-01-01
| | | | Run "TZ=UTC0 admin/update-copyright $(git ls-files)".
* Update copyright year to 2019Paul Eggert2019-01-01
| | | | Run 'TZ=UTC0 admin/update-copyright $(git ls-files)'.
* Update copyright year to 2018Paul Eggert2018-01-01
| | | | Run admin/update-copyright.
* Don't add empty keyboard macro to macro ring (Bug#24992)Gemini Lasswell2017-12-31
| | | | | | | | * lisp/kmacro.el (kmacro-end-call-mouse): Don't save a newly defined macro if it is empty. * test/lisp/kmacro-tests.el (kmacro-tests-end-and-call-macro-mouse): Remove expected failure tag.
* Fix errors in kmacro.el post-command-hookEli Zaretskii2017-10-16
| | | | | | | * lisp/kmacro.el (kmacro-step-edit-active): Initialize to nil to avoid 'void-variable' errors. (Bug#28818) * test/lisp/kmacro-tests.el (kmacro-tests-step-edit-cleans-up-hook): Now succeeds. (Bug#18708)
* ; Typo fixes, mostly repeated wordsPaul Eggert2017-10-09
|
* Prefer HTTPS to FTP and HTTP in documentationPaul Eggert2017-09-13
| | | | | | | | | | | | | Most of this change is to boilerplate commentary such as license URLs. This change was prompted by ftp://ftp.gnu.org's going-away party, planned for November. Change these FTP URLs to https://ftp.gnu.org instead. Make similar changes for URLs to other organizations moving away from FTP. Also, change HTTP to HTTPS for URLs to gnu.org and fsf.org when this works, as this will further help defend against man-in-the-middle attacks (for this part I omitted the MS-DOS and MS-Windows sources and the test tarballs to keep the workload down). HTTPS is not fully working to lists.gnu.org so I left those URLs alone for now.
* * test/lisp/kmacro-tests.el: Require seq, for seq-concatenate.Glenn Morris2017-04-18
|
* Add tests for lisp/kmacro.elGemini Lasswell2017-02-04
* test/lisp/kmacro-tests.el: New file. (Bug#24939)