diff options
author | Yuan Fu <casouri@gmail.com> | 2023-02-02 18:23:21 -0800 |
---|---|---|
committer | Yuan Fu <casouri@gmail.com> | 2023-02-02 18:32:08 -0800 |
commit | d963a8f1355a6d829af3f98182e66705c941e774 (patch) | |
tree | 23768d527db2dc85e9332c0443b2c6c53588782f /lisp/emacs-lisp/timer-list.el | |
parent | 8a6bdf88b4b665916cf74dee3a30e9136a9b6df8 (diff) | |
download | emacs-d963a8f1355a6d829af3f98182e66705c941e774.tar.gz emacs-d963a8f1355a6d829af3f98182e66705c941e774.tar.bz2 emacs-d963a8f1355a6d829af3f98182e66705c941e774.zip |
Make c-ts-mode indent tests side-effect-free
Running indent tests changes the global value of
c-ts-mode-indent-style. That's not good. This change fixes that.
I also refactored the indent style functions a bit.
* lisp/progmodes/c-ts-mode.el:
(c-ts-mode--prompt-for-style): New function.
(c-ts-mode-set-local-style): New function.
(c-ts-mode-set-style): Use c-ts-mode--prompt-for-style. Use
derived-mode-p when testing for major mode. Remove check of current
buffer's major mode since it doesn't matter.
* test/lisp/progmodes/c-ts-mode-resources/indent-bsd.erts:
* test/lisp/progmodes/c-ts-mode-resources/indent.erts: Use
c-ts-mode-set-local-style to set the indent style locally.
Diffstat (limited to 'lisp/emacs-lisp/timer-list.el')
0 files changed, 0 insertions, 0 deletions