]> git.eshelyaron.com Git - emacs.git/commitdiff
indent.erts (Code): Don't modify the global state
authorStefan Monnier <monnier@iro.umontreal.ca>
Wed, 19 Mar 2025 19:47:11 +0000 (15:47 -0400)
committerEshel Yaron <me@eshelyaron.com>
Sun, 23 Mar 2025 18:08:53 +0000 (19:08 +0100)
* test/lisp/progmodes/java-ts-mode-resources/indent.erts (Code):
Use `setq-local` and correspondingly move the remaining
assignment after activating the major mode.

(cherry picked from commit 5432331a62522c096246ef995a5b41dc067d25a9)

test/lisp/progmodes/java-ts-mode-resources/indent.erts

index 180f4358a0a891de746adffef032ab8681be2acb..bc0ba3b937348a48167591130cee41d5982ad154 100644 (file)
@@ -1,8 +1,8 @@
 Code:
   (lambda ()
-    (setq java-ts-mode-indent-offset 4)
     (java-ts-mode)
-    (setq indent-tabs-mode nil)
+    (setq-local java-ts-mode-indent-offset 4)
+    (setq-local indent-tabs-mode nil)
     (indent-region (point-min) (point-max)))
 
 Point-Char: |