<feed xmlns='http://www.w3.org/2005/Atom'>
<title>emacs/test/lisp/progmodes/c-ts-mode-resources, branch scratch/exec-byte-code</title>
<subtitle>Emacs is the extensible, customizable, self-documenting real-time display editor. 
</subtitle>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/'/>
<entry>
<title>Fix c-ts-mode indentation (bug#75442)</title>
<updated>2025-01-13T06:23:36+00:00</updated>
<author>
<name>Yuan Fu</name>
</author>
<published>2025-01-13T06:23:36+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=04032cd00af7617c709140f3c80b5604b05c11e8'/>
<id>04032cd00af7617c709140f3c80b5604b05c11e8</id>
<content type='text'>
* lisp/progmodes/c-ts-mode.el (c-ts-mode--simple-indent-rules):
Use standalone-parent instead of parent.
* test/lisp/progmodes/c-ts-mode-resources/indent.erts:
New test.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* lisp/progmodes/c-ts-mode.el (c-ts-mode--simple-indent-rules):
Use standalone-parent instead of parent.
* test/lisp/progmodes/c-ts-mode-resources/indent.erts:
New test.
</pre>
</div>
</content>
</entry>
<entry>
<title>; Indent by 8 in BSD indent tests for c-ts-mode</title>
<updated>2024-12-02T01:53:23+00:00</updated>
<author>
<name>Yuan Fu</name>
</author>
<published>2024-12-02T00:47:53+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=de98b5a24f2b2ad293b4298bb898842b8f23e5bc'/>
<id>de98b5a24f2b2ad293b4298bb898842b8f23e5bc</id>
<content type='text'>
* test/lisp/progmodes/c-ts-mode-resources/indent-bsd.erts: Set
indent offset to 8.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* test/lisp/progmodes/c-ts-mode-resources/indent-bsd.erts: Set
indent offset to 8.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add more c-ts-mode indent tests</title>
<updated>2024-12-02T01:53:23+00:00</updated>
<author>
<name>Yuan Fu</name>
</author>
<published>2024-12-01T07:49:14+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=44fcd37a486399be048fb03b9456497af78632fe'/>
<id>44fcd37a486399be048fb03b9456497af78632fe</id>
<content type='text'>
* test/lisp/progmodes/c-ts-mode-resources/indent-bsd.erts: Fix
label test.
* test/lisp/progmodes/c-ts-mode-resources/indent.erts: Add some
test, make other tests harder.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* test/lisp/progmodes/c-ts-mode-resources/indent-bsd.erts: Fix
label test.
* test/lisp/progmodes/c-ts-mode-resources/indent.erts: Add some
test, make other tests harder.
</pre>
</div>
</content>
</entry>
<entry>
<title>Improve c-ts-mode compound indents (bug#74507)</title>
<updated>2024-12-02T01:53:21+00:00</updated>
<author>
<name>Jørgen Kvalsvik</name>
</author>
<published>2024-11-19T07:01:01+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=c65c5d02224335562be7e04dd1bf185dfca3dbf1'/>
<id>c65c5d02224335562be7e04dd1bf185dfca3dbf1</id>
<content type='text'>
Properly indent the body of compound expressions, even when then
compound expression is not at the beginning of line and the
parent is not an if/for/while/etc., and matches the behavior of
c-mode.

This fixes a problem that is common with macros and in testing
frameworks. For example, you expect this to indent:

TEST_CASE(1) {
    assert (...);
}

If the compound statement is the function body itself, don't
apply this new rule and instead guide by the parent and first
sibling.

I'm sure there are subtle interactions that aren't handled
properly by checking for "function_definition" rather than
something more general, but it does fix the test case and the
check can be improved as more cases are found.

* lisp/progmodes/c-ts-mode.el:
(c-ts-mode--parent-is-not-top-compound): New function.
(c-ts-mode--indent-styles): Use it.
* test/lisp/progmodes/c-ts-mode-resources/indent.erts: New
compound statement test.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Properly indent the body of compound expressions, even when then
compound expression is not at the beginning of line and the
parent is not an if/for/while/etc., and matches the behavior of
c-mode.

This fixes a problem that is common with macros and in testing
frameworks. For example, you expect this to indent:

TEST_CASE(1) {
    assert (...);
}

If the compound statement is the function body itself, don't
apply this new rule and instead guide by the parent and first
sibling.

I'm sure there are subtle interactions that aren't handled
properly by checking for "function_definition" rather than
something more general, but it does fix the test case and the
check can be improved as more cases are found.

* lisp/progmodes/c-ts-mode.el:
(c-ts-mode--parent-is-not-top-compound): New function.
(c-ts-mode--indent-styles): Use it.
* test/lisp/progmodes/c-ts-mode-resources/indent.erts: New
compound statement test.
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge from origin/emacs-30</title>
<updated>2024-10-27T12:23:06+00:00</updated>
<author>
<name>Eli Zaretskii</name>
</author>
<published>2024-10-27T12:23:06+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=aeaeccbe3219c655b091fa3867c87b02b6289a1b'/>
<id>aeaeccbe3219c655b091fa3867c87b02b6289a1b</id>
<content type='text'>
c78b4d2b31d Fix doc string of 'wdired-use-dired-vertical-movement'
b0aaee93fde Update the documentation of void functions
299a1f24075 ; * lisp/vc/log-edit.el (log-edit-diff-function): Grammar...
67a27ff53bf ; Fix typos
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
c78b4d2b31d Fix doc string of 'wdired-use-dired-vertical-movement'
b0aaee93fde Update the documentation of void functions
299a1f24075 ; * lisp/vc/log-edit.el (log-edit-diff-function): Grammar...
67a27ff53bf ; Fix typos
</pre>
</div>
</content>
</entry>
<entry>
<title>; Fix typos</title>
<updated>2024-10-27T06:49:32+00:00</updated>
<author>
<name>Stefan Kangas</name>
</author>
<published>2024-10-27T06:49:32+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=67a27ff53bf0f8473cb6b58ad85298e066b8def4'/>
<id>67a27ff53bf0f8473cb6b58ad85298e066b8def4</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge from origin/emacs-30</title>
<updated>2024-10-18T15:56:08+00:00</updated>
<author>
<name>Michael Albinus</name>
</author>
<published>2024-10-18T15:56:08+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=674ad2ba7fc2ce21eff823ee3c6bfbc42da59520'/>
<id>674ad2ba7fc2ce21eff823ee3c6bfbc42da59520</id>
<content type='text'>
78e6328fafd ; (select-safe-coding-system-interactively): Say "safely ...
c5eba443ae7 ; * lisp/icomplete.el (icomplete-in-buffer): Doc fix (bug...
569186c36e3 ; * doc/lispref/display.texi (Face Attributes): Fix typo ...
d5723fc4f03 * lisp/progmodes/c-ts-mode.el (treesit-node-eq): Declare ...
0085e48f917 * admin/notes/emba: Docker builds do not run in a worktree.
3d30905b022 * lisp/calc/calc-ext.el (math-approx-sqrt-e): Doc fix (bu...
94d0e9c4018 : Revert a mistaken change
4d90a1d8209 ; * doc/emacs/search.texi (Word Search): Spelling fixes.
c154047c46a Fix c-ts-mode--anchor-prev-sibling (bug#73661)
b87fda63dd4 Fix formatting of long keyboard macros by 'list-keyboard-...
ae75ea62324 ; * src/fileio.c (Ffile_newer_than_file_p): Fix wording (...
b1203978685 Merge branch 'emacs-30' of git.sv.gnu.org:/srv/git/emacs ...
de54d922b5c * doc/emacs/mini.texi (Passwords): Mention password visib...
0f8f0773183 ; * doc/emacs/search.texi (Word Search): Document 'dictio...
fb155bcfb6f ; * lisp/emacs-lisp/chart.el (chart-bar-quickie): Doc fix.
6dbe4e99ac4 ; * lisp/emacs-lisp/chart.el (chart-bar-quickie): Improve...
d664227f81a ; More accurate documentation of 'file-newer-than-file-p'
e49b479f869 Fix c-ts-mode indentation for initializer lists (bug#73661)
f520008744b Avoid segfaults in Rmail-MIME
6a5c2edd84f Eglot: use :immediate t when resolving completions (bug#7...
cd36e070c24 Eglot: minor changes to doc and docstrings
1ea0d9b891b Revert "Set treesit-primary-parser for tree-sitter modes"
52746ceb625 Remove duplicate indent rules in elixir-ts-mode
ed57faafc74 Set treesit-primary-parser for tree-sitter modes
37a6c859b04 ; * lisp/emacs-lisp/cl-macs.el (cl-once-only): Fix capita...
2d4d6dc43a4 Delete XIE X extension from TODO
b68b9f291cc ; * lisp/progmodes/csharp-mode.el (treesit-query-compile)...
688201ef18d ; * lisp/window.el (switch-to-prev-buffer-skip-regexp): D...
ba44fc9a447 Restore comment/string check for 'electric-layout-mode'
5a462948e13 Update Arni Magnusson's email address
6b1271b169a Fix python-ts-mode-map docstring
aaaafddc945 Normalize "Commentary" section in eudc.el
d656be9794d Expand email abbrevs in X-Debbugs-Cc header.
e9dcf0c57dd Fix 'list-tags' when invoked from a non-file buffer
51ef05f684c count-windows: Fix reference to walk-windows
5eaf0c784bf * lisp/info-look.el (mapc): Add use-package manual's index.
705a5a1a9e6 ; * ChangeLog.4: Fix attribution of one change.
bf26ff0dc8d Update csharp-ts-mode font-lock (bug#73369)
4c866abab96 ; * doc/lispref/variables.texi (Creating Buffer-Local): F...
d42d7d474fe ; * lisp/doc-view.el (doc-view-svg-face): Copy-edit docst...
f46f476bb8f ; * admin/MAINTAINERS: Take VC subsystem, add note about ...
d68e6d2689d ; rcirc-update-activity-string: Justify some existing beh...
e6a37869c8d Fix inconsistency in value of rcirc-activity-string
108b3179bd4 Revert "; Minor clarification in variables.texi"
44156c21407 ; Minor clarification in variables.texi
63058e1153a Tag interactive commands in 'lua-ts-mode'
84bea20eba2 ; * lisp/info-look.el: Add two more links.
96b87ad5363 Mention LSP acronym in eglot defgroup docstring
9c904e8ceae Change :group of 'eglot' defgroup to 'tools'
fd1a1b07805 Remove out-of-date documentation from python.el
11e3e0cadd4 Fix executing commands in Eshell using "env" with no loca...
c0ef8a9a1b3 Fix a typo in the calendar manual
36ff7138feb ; Fix a thinko in sieve-manage.el
7abecbcd633 ; * nt/INSTALL: Update MinGW notes URL.  (Bug#73528)
e2b01d164cd ; Fix last changes in php-ts-mode.el
e8830015b07 Require ert-x for use by 'ert-font-lock-deftest-file'
a1841b4d8e7 ; * admin/authors.el (authors-aliases): Don't ignore "one...
69d8f9d1b70 Fix php-ts-mode font-lock for latest PHP grammar (bug#73516)
68f53e43488 eieio.texi: Fix bug#73505
53c887fdf6d ; cperl-mode.el: Fix an invalid face specification
f5cd5585f46 ; Recommend GNU Find for 'find-dired'
65e589698e6 ; * lisp/filesets.el (filesets-homepage): Fix URL.
1f243a97806 Delete duplicated line in Viper refcard
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
78e6328fafd ; (select-safe-coding-system-interactively): Say "safely ...
c5eba443ae7 ; * lisp/icomplete.el (icomplete-in-buffer): Doc fix (bug...
569186c36e3 ; * doc/lispref/display.texi (Face Attributes): Fix typo ...
d5723fc4f03 * lisp/progmodes/c-ts-mode.el (treesit-node-eq): Declare ...
0085e48f917 * admin/notes/emba: Docker builds do not run in a worktree.
3d30905b022 * lisp/calc/calc-ext.el (math-approx-sqrt-e): Doc fix (bu...
94d0e9c4018 : Revert a mistaken change
4d90a1d8209 ; * doc/emacs/search.texi (Word Search): Spelling fixes.
c154047c46a Fix c-ts-mode--anchor-prev-sibling (bug#73661)
b87fda63dd4 Fix formatting of long keyboard macros by 'list-keyboard-...
ae75ea62324 ; * src/fileio.c (Ffile_newer_than_file_p): Fix wording (...
b1203978685 Merge branch 'emacs-30' of git.sv.gnu.org:/srv/git/emacs ...
de54d922b5c * doc/emacs/mini.texi (Passwords): Mention password visib...
0f8f0773183 ; * doc/emacs/search.texi (Word Search): Document 'dictio...
fb155bcfb6f ; * lisp/emacs-lisp/chart.el (chart-bar-quickie): Doc fix.
6dbe4e99ac4 ; * lisp/emacs-lisp/chart.el (chart-bar-quickie): Improve...
d664227f81a ; More accurate documentation of 'file-newer-than-file-p'
e49b479f869 Fix c-ts-mode indentation for initializer lists (bug#73661)
f520008744b Avoid segfaults in Rmail-MIME
6a5c2edd84f Eglot: use :immediate t when resolving completions (bug#7...
cd36e070c24 Eglot: minor changes to doc and docstrings
1ea0d9b891b Revert "Set treesit-primary-parser for tree-sitter modes"
52746ceb625 Remove duplicate indent rules in elixir-ts-mode
ed57faafc74 Set treesit-primary-parser for tree-sitter modes
37a6c859b04 ; * lisp/emacs-lisp/cl-macs.el (cl-once-only): Fix capita...
2d4d6dc43a4 Delete XIE X extension from TODO
b68b9f291cc ; * lisp/progmodes/csharp-mode.el (treesit-query-compile)...
688201ef18d ; * lisp/window.el (switch-to-prev-buffer-skip-regexp): D...
ba44fc9a447 Restore comment/string check for 'electric-layout-mode'
5a462948e13 Update Arni Magnusson's email address
6b1271b169a Fix python-ts-mode-map docstring
aaaafddc945 Normalize "Commentary" section in eudc.el
d656be9794d Expand email abbrevs in X-Debbugs-Cc header.
e9dcf0c57dd Fix 'list-tags' when invoked from a non-file buffer
51ef05f684c count-windows: Fix reference to walk-windows
5eaf0c784bf * lisp/info-look.el (mapc): Add use-package manual's index.
705a5a1a9e6 ; * ChangeLog.4: Fix attribution of one change.
bf26ff0dc8d Update csharp-ts-mode font-lock (bug#73369)
4c866abab96 ; * doc/lispref/variables.texi (Creating Buffer-Local): F...
d42d7d474fe ; * lisp/doc-view.el (doc-view-svg-face): Copy-edit docst...
f46f476bb8f ; * admin/MAINTAINERS: Take VC subsystem, add note about ...
d68e6d2689d ; rcirc-update-activity-string: Justify some existing beh...
e6a37869c8d Fix inconsistency in value of rcirc-activity-string
108b3179bd4 Revert "; Minor clarification in variables.texi"
44156c21407 ; Minor clarification in variables.texi
63058e1153a Tag interactive commands in 'lua-ts-mode'
84bea20eba2 ; * lisp/info-look.el: Add two more links.
96b87ad5363 Mention LSP acronym in eglot defgroup docstring
9c904e8ceae Change :group of 'eglot' defgroup to 'tools'
fd1a1b07805 Remove out-of-date documentation from python.el
11e3e0cadd4 Fix executing commands in Eshell using "env" with no loca...
c0ef8a9a1b3 Fix a typo in the calendar manual
36ff7138feb ; Fix a thinko in sieve-manage.el
7abecbcd633 ; * nt/INSTALL: Update MinGW notes URL.  (Bug#73528)
e2b01d164cd ; Fix last changes in php-ts-mode.el
e8830015b07 Require ert-x for use by 'ert-font-lock-deftest-file'
a1841b4d8e7 ; * admin/authors.el (authors-aliases): Don't ignore "one...
69d8f9d1b70 Fix php-ts-mode font-lock for latest PHP grammar (bug#73516)
68f53e43488 eieio.texi: Fix bug#73505
53c887fdf6d ; cperl-mode.el: Fix an invalid face specification
f5cd5585f46 ; Recommend GNU Find for 'find-dired'
65e589698e6 ; * lisp/filesets.el (filesets-homepage): Fix URL.
1f243a97806 Delete duplicated line in Viper refcard
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix c-ts-mode--anchor-prev-sibling (bug#73661)</title>
<updated>2024-10-15T03:23:15+00:00</updated>
<author>
<name>Yuan Fu</name>
</author>
<published>2024-10-15T02:31:12+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=c154047c46ae833a114e84d72e62269d12c3249d'/>
<id>c154047c46ae833a114e84d72e62269d12c3249d</id>
<content type='text'>
* lisp/progmodes/c-ts-mode.el:
(c-ts-mode--anchor-prev-sibling):  Fix parentheses and use a
slightly more efficient function.
* test/lisp/progmodes/c-ts-mode-resources/indent.erts: Replace
the tab in the test code with spaces.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* lisp/progmodes/c-ts-mode.el:
(c-ts-mode--anchor-prev-sibling):  Fix parentheses and use a
slightly more efficient function.
* test/lisp/progmodes/c-ts-mode-resources/indent.erts: Replace
the tab in the test code with spaces.
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge from origin/emacs-30</title>
<updated>2024-10-12T09:53:27+00:00</updated>
<author>
<name>Eli Zaretskii</name>
</author>
<published>2024-10-12T09:53:27+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=bb5b25181ea7a4393f019dc641a981bdb6687c62'/>
<id>bb5b25181ea7a4393f019dc641a981bdb6687c62</id>
<content type='text'>
0f8f0773183 ; * doc/emacs/search.texi (Word Search): Document 'dictio...
fb155bcfb6f ; * lisp/emacs-lisp/chart.el (chart-bar-quickie): Doc fix.
6dbe4e99ac4 ; * lisp/emacs-lisp/chart.el (chart-bar-quickie): Improve...
d664227f81a ; More accurate documentation of 'file-newer-than-file-p'
e49b479f869 Fix c-ts-mode indentation for initializer lists (bug#73661)
f520008744b Avoid segfaults in Rmail-MIME
6a5c2edd84f Eglot: use :immediate t when resolving completions (bug#7...
cd36e070c24 Eglot: minor changes to doc and docstrings
1ea0d9b891b Revert "Set treesit-primary-parser for tree-sitter modes"
52746ceb625 Remove duplicate indent rules in elixir-ts-mode
ed57faafc74 Set treesit-primary-parser for tree-sitter modes
37a6c859b04 ; * lisp/emacs-lisp/cl-macs.el (cl-once-only): Fix capita...
2d4d6dc43a4 Delete XIE X extension from TODO
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
0f8f0773183 ; * doc/emacs/search.texi (Word Search): Document 'dictio...
fb155bcfb6f ; * lisp/emacs-lisp/chart.el (chart-bar-quickie): Doc fix.
6dbe4e99ac4 ; * lisp/emacs-lisp/chart.el (chart-bar-quickie): Improve...
d664227f81a ; More accurate documentation of 'file-newer-than-file-p'
e49b479f869 Fix c-ts-mode indentation for initializer lists (bug#73661)
f520008744b Avoid segfaults in Rmail-MIME
6a5c2edd84f Eglot: use :immediate t when resolving completions (bug#7...
cd36e070c24 Eglot: minor changes to doc and docstrings
1ea0d9b891b Revert "Set treesit-primary-parser for tree-sitter modes"
52746ceb625 Remove duplicate indent rules in elixir-ts-mode
ed57faafc74 Set treesit-primary-parser for tree-sitter modes
37a6c859b04 ; * lisp/emacs-lisp/cl-macs.el (cl-once-only): Fix capita...
2d4d6dc43a4 Delete XIE X extension from TODO
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix c-ts-mode indentation for initializer lists (bug#73661)</title>
<updated>2024-10-10T07:05:42+00:00</updated>
<author>
<name>Jørgen Kvalsvik</name>
</author>
<published>2024-10-04T19:38:33+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=e49b479f8692573379a1ee3417bdda9e1f777888'/>
<id>e49b479f8692573379a1ee3417bdda9e1f777888</id>
<content type='text'>
The intentation behavior differed between c-mode/c++-mode
and *-ts-mode for initializer lists where the first element was
not at beginning-of-line.  The anchor-prev-sibling function gave
up and returned nil, but it should (probably) anchor on the
first element in the initializer list, such as this:

return { v1, v2, ...,
         y1, y2, ... };

c-ts-mode behaved better and figured out how to align, but I
added a test for a similar compound literal to prevent
regressions.

* lisp/progmodes/c-ts-mode.el (c-ts-mode--anchor-prev-sibling):
Anchor at first sibling unless bol is found.

* test/lisp/progmodes/c-ts-mode-resources/indent.erts: New
initializer list and compound literal test.

Copyright-paperwork-exempt: yes
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The intentation behavior differed between c-mode/c++-mode
and *-ts-mode for initializer lists where the first element was
not at beginning-of-line.  The anchor-prev-sibling function gave
up and returned nil, but it should (probably) anchor on the
first element in the initializer list, such as this:

return { v1, v2, ...,
         y1, y2, ... };

c-ts-mode behaved better and figured out how to align, but I
added a test for a similar compound literal to prevent
regressions.

* lisp/progmodes/c-ts-mode.el (c-ts-mode--anchor-prev-sibling):
Anchor at first sibling unless bol is found.

* test/lisp/progmodes/c-ts-mode-resources/indent.erts: New
initializer list and compound literal test.

Copyright-paperwork-exempt: yes
</pre>
</div>
</content>
</entry>
</feed>
