emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Breaking change with auto-filling in Org mode with recent commit


From: Kaushal Modi
Subject: Breaking change with auto-filling in Org mode with recent commit
Date: Wed, 09 Aug 2017 14:43:13 +0000

Hello,

I have noticed auto-filling to stop doing the right thing after commit http://git.savannah.gnu.org/cgit/emacs.git/commit/?id=9b463fa8648b7baed95a44f4317cb7402fd8bf1c

I have verified that reverting just that commit brings things back to stable state.

Examples in Org mode *with auto-fill-mode enabled*:

=====
#+BEGIN_SRC nim
# echo @["a", "b", "c"].join(' ') # Error: type mismatch: got (seq[string], char)
#+END_SRC
=====

Before commit 9b463fa8:
- With point at the end of that comment line starting with "echo", if I hit Enter, filling will *not* happen on that line.

After commit 9b463fa8:
- With point at the end of that comment line starting with "echo", if I hit Enter, filling will happen, resulting in invalid code:
=====
#+BEGIN_SRC nim
# echo @["a", "b", "c"].join(' ') # Error: type 
mismatch: got (seq[string], char)
#+END_SRC
=====

Another example:

=====
* Heading
1. =["a", "b", "c"].join(" ")= does not work, but =join(["a", "b", "c"], " ")= works.
=====

Before commit 9b463fa8:
- With point at the end of that Org list item, if I hit Enter, I will get:
=====
* Heading
1. =["a", "b", "c"].join(" ")= does not work, but =join(["a", "b",
   "c"], " ")= works.
=====
- Then if I hit M-RET, I get:
=====
* Heading
1. =["a", "b", "c"].join(" ")= does not work, but =join(["a", "b",
   "c"], " ")= works.
2.
=====
Notice that space inserted at the beginning of "   "c"], " ")= works." line is important!

After commit 9b463fa8:
- With point at the end of that Org list item, if I hit Enter, I will get:
=====
* Heading
1. =["a", "b", "c"].join(" ")= does not work, but =join(["a", "b",
"c"], " ")= works.
=====
- Then if I hit M-RET, I get:
=====
* Heading
1. =["a", "b", "c"].join(" ")= does not work, but =join(["a", "b",
"c"], " ")= works.
=====
As that extra space now not inserted, Org does not detect that I am trying to continue in the same list and starts a new Org heading.

I have just given an example using Org. The change in Emacs core though seems to have broken the fundamental operation of auto-filling in comments.
--

Kaushal Modi


reply via email to

[Prev in Thread] Current Thread [Next in Thread]