GNU bug report logs - #47784
27.2: ses-header-row [PATCH INCLUDED]

Previous Next

Package: emacs;

Reported by: Boruch Baum <boruch_baum <at> gmx.com>

Date: Thu, 15 Apr 2021 03:32:02 UTC

Severity: normal

Tags: fixed, patch

Found in version 27.2

Fixed in version 28.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 47784 in the body.
You can then email your comments to 47784 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Thu, 15 Apr 2021 03:32:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Boruch Baum <boruch_baum <at> gmx.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Thu, 15 Apr 2021 03:32:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Boruch Baum <boruch_baum <at> gmx.com>
To: Emacs Bug Reporting <bug-gnu-emacs <at> gnu.org>
Subject: 27.2: ses-header-row [PATCH INCLUDED]
Date: Wed, 14 Apr 2021 23:31:47 -0400
[Message part 1 (text/plain, inline)]
Two patch files are attached.

+ ses-header-row.patch

  + Function `ses-set-header-row' was determining the current row based
    upon variable `ses--curcell', but that variable is NIL until one
    begins an operation on a cell (eg. keybindings '=', '"'), so
    navigating to a row was insufficient to select that row, and further
    generated an ERROR because the code was not expecting a NIL value for
    variable `ses--curcell'

  + Using function `user-error' instead of `error' doesn't spawn a
    debug session and backtrace buffer when variable
    `toggle-debug-on-error' is set.

+ ses-user-error.patch

  + Quasi-randomly replaces some calls to function `error' with
    `user-error'.

  + There could be many other desirable points of replacement, but these
    were some obvious ones, and without knowing whether the patch would
    be accepted at all, it's what I invested.


--
hkp://keys.gnupg.net
CA45 09B5 5351 7C11 A9D1  7286 0036 9E45 1595 8BC0
[ses-header-row.patch (text/x-diff, attachment)]
[ses-user-error.patch (text/x-diff, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Sat, 17 Apr 2021 19:31:01 GMT) Full text and rfc822 format available.

Message #8 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Boruch Baum <boruch_baum <at> gmx.com>
Cc: 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Sat, 17 Apr 2021 22:30:08 +0300
> Date: Wed, 14 Apr 2021 23:31:47 -0400
> From: Boruch Baum <boruch_baum <at> gmx.com>
> 
> Two patch files are attached.
> 
> + ses-header-row.patch
> 
>   + Function `ses-set-header-row' was determining the current row based
>     upon variable `ses--curcell', but that variable is NIL until one
>     begins an operation on a cell (eg. keybindings '=', '"'), so
>     navigating to a row was insufficient to select that row, and further
>     generated an ERROR because the code was not expecting a NIL value for
>     variable `ses--curcell'
> 
>   + Using function `user-error' instead of `error' doesn't spawn a
>     debug session and backtrace buffer when variable
>     `toggle-debug-on-error' is set.
> 
> + ses-user-error.patch
> 
>   + Quasi-randomly replaces some calls to function `error' with
>     `user-error'.
> 
>   + There could be many other desirable points of replacement, but these
>     were some obvious ones, and without knowing whether the patch would
>     be accepted at all, it's what I invested.

Thanks, but I don't think I understand the rationale for the second
patch.  What is the problem with signaling an error in those two
places?




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Mon, 19 Apr 2021 09:25:01 GMT) Full text and rfc822 format available.

Message #11 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Boruch Baum <boruch_baum <at> gmx.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Mon, 19 Apr 2021 05:24:30 -0400
On 2021-04-17 22:30, Eli Zaretskii wrote:
> > Date: Wed, 14 Apr 2021 23:31:47 -0400
> > From: Boruch Baum <boruch_baum <at> gmx.com>

> > ...

> > + ses-user-error.patch
> >
> >   + Quasi-randomly replaces some calls to function `error' with
> >     `user-error'.
> >
> >   + There could be many other desirable points of replacement, but these
> >     were some obvious ones, and without knowing whether the patch would
> >     be accepted at all, it's what I invested.
>
> Thanks, but I don't think I understand the rationale for the second
> patch.  What is the problem with signaling an error in those two
> places?

They avoid spawning a backtrace buffer when toggle-debug-on-error is set
and the error is a user input error caught by a validation test within
an `interactive' function call.

--
hkp://keys.gnupg.net
CA45 09B5 5351 7C11 A9D1  7286 0036 9E45 1595 8BC0




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Mon, 19 Apr 2021 13:04:02 GMT) Full text and rfc822 format available.

Message #14 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Boruch Baum <boruch_baum <at> gmx.com>
Cc: 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Mon, 19 Apr 2021 16:03:12 +0300
> Date: Mon, 19 Apr 2021 05:24:30 -0400
> From: Boruch Baum <boruch_baum <at> gmx.com>
> Cc: 47784 <at> debbugs.gnu.org
> 
> > Thanks, but I don't think I understand the rationale for the second
> > patch.  What is the problem with signaling an error in those two
> > places?
> 
> They avoid spawning a backtrace buffer when toggle-debug-on-error is set
> and the error is a user input error caught by a validation test within
> an `interactive' function call.

I understand that, but the same is true for every call to 'error'
whenever debug-on-error is set.  Since by default debug-on-error is
NOT set, I don't think I agree with that part of the change.  (Why do
you even have that variable set non-nil?)




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Mon, 19 Apr 2021 13:29:02 GMT) Full text and rfc822 format available.

Message #17 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Boruch Baum <boruch_baum <at> gmx.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Mon, 19 Apr 2021 09:27:52 -0400
On 2021-04-19 16:03, Eli Zaretskii wrote:
> > Date: Mon, 19 Apr 2021 05:24:30 -0400
> > From: Boruch Baum <boruch_baum <at> gmx.com>
> > Cc: 47784 <at> debbugs.gnu.org
> >
> > > Thanks, but I don't think I understand the rationale for the second
> > > patch.  What is the problem with signaling an error in those two
> > > places?
> >
> > They avoid spawning a backtrace buffer when toggle-debug-on-error is set
> > and the error is a user input error caught by a validation test within
> > an `interactive' function call.
>
> I understand that, but the same is true for every call to 'error'
> whenever debug-on-error is set.

Not at all. The specific metrics are:

  1) validation of user-input
  2) interactive call

Decide what your opinion is the purpose of function `user-error'
separate from `error' and act accordingly. Whatever metric you use,
you're bound to find cases of `error' being misused when `user-error'
should be used.

--
hkp://keys.gnupg.net
CA45 09B5 5351 7C11 A9D1  7286 0036 9E45 1595 8BC0




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Wed, 21 Apr 2021 00:03:02 GMT) Full text and rfc822 format available.

Message #20 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: Boruch Baum <boruch_baum <at> gmx.com>, 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Tue, 20 Apr 2021 19:02:26 -0500
Eli Zaretskii <eliz <at> gnu.org> writes:

>> > Thanks, but I don't think I understand the rationale for the second
>> > patch.  What is the problem with signaling an error in those two
>> > places?
>>
>> They avoid spawning a backtrace buffer when toggle-debug-on-error is set
>> and the error is a user input error caught by a validation test within
>> an `interactive' function call.
>
> I understand that, but the same is true for every call to 'error'
> whenever debug-on-error is set.  Since by default debug-on-error is
> NOT set, I don't think I agree with that part of the change.  (Why do
> you even have that variable set non-nil?)

AFAIU, `user-error' is to be used when, according to its docstring:

    This is like ‘error’ except that a user error (or "pilot error") comes
    from an incorrect manipulation by the user, not from an actual problem.

So if that is the case here, then it should be `user-error's and
otherwise it should be plain `error's.  Right?




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Wed, 21 Apr 2021 09:24:01 GMT) Full text and rfc822 format available.

Message #23 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Stefan Kangas <stefan <at> marxist.se>
Cc: boruch_baum <at> gmx.com, 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Wed, 21 Apr 2021 12:23:22 +0300
> From: Stefan Kangas <stefan <at> marxist.se>
> Date: Tue, 20 Apr 2021 19:02:26 -0500
> Cc: Boruch Baum <boruch_baum <at> gmx.com>, 47784 <at> debbugs.gnu.org
> 
> >> They avoid spawning a backtrace buffer when toggle-debug-on-error is set
> >> and the error is a user input error caught by a validation test within
> >> an `interactive' function call.
> >
> > I understand that, but the same is true for every call to 'error'
> > whenever debug-on-error is set.  Since by default debug-on-error is
> > NOT set, I don't think I agree with that part of the change.  (Why do
> > you even have that variable set non-nil?)
> 
> AFAIU, `user-error' is to be used when, according to its docstring:
> 
>     This is like ‘error’ except that a user error (or "pilot error") comes
>     from an incorrect manipulation by the user, not from an actual problem.
> 
> So if that is the case here, then it should be `user-error's and
> otherwise it should be plain `error's.  Right?

How do you establish whether a particular problem is due to "incorrect
manipulation by the user"?  Since almost everything in Emacs comes
from the user, one way or another, every error is due to "incorrect
manipulation" of some kind.  OTOH, commands can also be invoked from
Lisp, non-interactively, in which case the user may have nothing to do
with the problem, at least not directly.

With that in mind, please look at the code where Boruch suggested to
make these changes, and tell me what you think about them.

Boruch's rationale was a different one, it stems from running with
debug-on-error set non-nil.  But that is a very unusual thing to do,
and is bound to produce annoying backtraces all over the place.  So
I'm not sure I share the opinion that these changes should be made.  I
would like to hear other opinions, though.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Wed, 05 May 2021 13:10:01 GMT) Full text and rfc822 format available.

Message #26 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Boruch Baum <boruch_baum <at> gmx.com>
Cc: 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Wed, 05 May 2021 15:08:52 +0200
Boruch Baum <boruch_baum <at> gmx.com> writes:

> Two patch files are attached.
>
> + ses-header-row.patch
>
>   + Function `ses-set-header-row' was determining the current row based
>     upon variable `ses--curcell', but that variable is NIL until one
>     begins an operation on a cell (eg. keybindings '=', '"'), so
>     navigating to a row was insufficient to select that row, and further
>     generated an ERROR because the code was not expecting a NIL value for
>     variable `ses--curcell'
>
>   + Using function `user-error' instead of `error' doesn't spawn a
>     debug session and backtrace buffer when variable
>     `toggle-debug-on-error' is set.
>
> + ses-user-error.patch
>
>   + Quasi-randomly replaces some calls to function `error' with
>     `user-error'.

Looks good to me, so I've applied both patches to Emacs 28.  Eli had
some questions about the usage of user-error instead of error in the
second patch, but as far as I can tell, using `user-error' is indeed the
right thing here, because the errors in question seem more user
initiated.

I've got two tiny comments about the patch.  First of all, the
whitespace seemed odd:

lisp/ses.el:3462: space before tab in indent.
+         	  (currow (1+ (car (ses-sym-rowcol curcell)))))

So I fixed that up, but I've seen that in other patches -- could you
have a look and see what's causing this mixture of tab and spaces?

The other comment is that it would be nice to have ChangeLog-style
commit messages -- use `C-x 4 a' to format one before sending patches.
Less work when applying the patch.  :-)

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Added tag(s) fixed. Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Wed, 05 May 2021 13:10:02 GMT) Full text and rfc822 format available.

bug marked as fixed in version 28.1, send any further explanations to 47784 <at> debbugs.gnu.org and Boruch Baum <boruch_baum <at> gmx.com> Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Wed, 05 May 2021 13:10:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Wed, 05 May 2021 16:41:01 GMT) Full text and rfc822 format available.

Message #33 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Boruch Baum <boruch_baum <at> gmx.com>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Wed, 5 May 2021 12:40:34 -0400
On 2021-05-05 15:08, Lars Ingebrigtsen wrote:
> I've got two tiny comments about the patch.  First of all, the
> whitespace seemed odd:
> ...
> So I fixed that up, but I've seen that in other patches -- could you
> have a look and see what's causing this mixture of tab and spaces?

I could use a suggestion to automate that workflow: I never use tabs,
but often find myself editing files that have them. As soon as it gets
annoying, I remember to perform untabify on the buffer, but there's
probably an accepted automated method to respect the tab/space
preferences of everyone.

> The other comment is that it would be nice to have ChangeLog-style
> commit messages -- use `C-x 4 a' to format one before sending patches.
> Less work when applying the patch.  :-)

I use `C-x 4 a' a lot, but for Changelog files. How can it be used for
commit messages? Are you suggesting a temporary fake Changelog file? I
see the output now in the online gnu cgit repository, so that's do-able
manually. Are you saying that there's an automated way using function
`add-change-log-entry-other-window'?

--
hkp://keys.gnupg.net
CA45 09B5 5351 7C11 A9D1  7286 0036 9E45 1595 8BC0




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Wed, 05 May 2021 19:16:02 GMT) Full text and rfc822 format available.

Message #36 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Boruch Baum <boruch_baum <at> gmx.com>
Cc: larsi <at> gnus.org, 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Wed, 05 May 2021 22:15:17 +0300
> Date: Wed, 5 May 2021 12:40:34 -0400
> From: Boruch Baum <boruch_baum <at> gmx.com>
> Cc: 47784 <at> debbugs.gnu.org
> 
> I use `C-x 4 a' a lot, but for Changelog files. How can it be used for
> commit messages? Are you suggesting a temporary fake Changelog file?

"C-x 4 a" will automatically produce a ChangeLog-formatted buffer,
from which you could copy the log message when you commit.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Wed, 05 May 2021 19:41:01 GMT) Full text and rfc822 format available.

Message #39 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Boruch Baum <boruch_baum <at> gmx.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: larsi <at> gnus.org, 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Wed, 5 May 2021 15:40:46 -0400
On 2021-05-05 22:15, Eli Zaretskii wrote:
> > Date: Wed, 5 May 2021 12:40:34 -0400
> > From: Boruch Baum <boruch_baum <at> gmx.com>
> > Cc: 47784 <at> debbugs.gnu.org
> >
> > I use `C-x 4 a' a lot, but for Changelog files. How can it be used for
> > commit messages? Are you suggesting a temporary fake Changelog file?
>
> "C-x 4 a" will automatically produce a ChangeLog-formatted buffer,
> from which you could copy the log message when you commit.

Is this some new and 'backward-incompatible' behavior? In the past, I
remember it always creating a Changelog file...

--
hkp://keys.gnupg.net
CA45 09B5 5351 7C11 A9D1  7286 0036 9E45 1595 8BC0




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Wed, 05 May 2021 19:48:02 GMT) Full text and rfc822 format available.

Message #42 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Boruch Baum <boruch_baum <at> gmx.com>
Cc: larsi <at> gnus.org, 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Wed, 05 May 2021 22:46:35 +0300
> Date: Wed, 5 May 2021 15:40:46 -0400
> From: Boruch Baum <boruch_baum <at> gmx.com>
> Cc: larsi <at> gnus.org, 47784 <at> debbugs.gnu.org
> 
> > "C-x 4 a" will automatically produce a ChangeLog-formatted buffer,
> > from which you could copy the log message when you commit.
> 
> Is this some new and 'backward-incompatible' behavior?

It's new, but not backward-incompatible, I think.  AFAIR it only
happens when the buffer visits a versioned file.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Thu, 06 May 2021 08:11:01 GMT) Full text and rfc822 format available.

Message #45 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Robert Pluim <rpluim <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: larsi <at> gnus.org, Boruch Baum <boruch_baum <at> gmx.com>, 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Thu, 06 May 2021 10:10:44 +0200
>>>>> On Wed, 05 May 2021 22:46:35 +0300, Eli Zaretskii <eliz <at> gnu.org> said:

    >> Date: Wed, 5 May 2021 15:40:46 -0400
    >> From: Boruch Baum <boruch_baum <at> gmx.com>
    >> Cc: larsi <at> gnus.org, 47784 <at> debbugs.gnu.org
    >> 
    >> > "C-x 4 a" will automatically produce a ChangeLog-formatted buffer,
    >> > from which you could copy the log message when you commit.
    >> 
    >> Is this some new and 'backward-incompatible' behavior?

    Eli> It's new, but not backward-incompatible, I think.  AFAIR it only
    Eli> happens when the buffer visits a versioned file.

From NEWS.27:

    *** New command 'log-edit-generate-changelog-from-diff', bound to 'C-c C-w'.
    This generates ChangeLog entries from the VC fileset diff.

    *** Recording ChangeLog entries doesn't require an actual file.
    If a ChangeLog file doesn't exist, and if the new user option
    'add-log-dont-create-changelog-file' is non-nil (which is the
    default), commands such as 'C-x 4 a' will add log entries to a
    suitable named temporary buffer.  (An existing ChangeLog file will
    still be used if it exists.)  Set the user option to nil to get the
    previous behavior of always creating a buffer that visits a ChangeLog
    file.

If you use vc, then 'vc-checkin' will copy the log message from the
ChangeLog to the commit log edit buffer for you (and that I think itʼs
been doing for a long time).

Robert
-- 




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Thu, 06 May 2021 08:18:01 GMT) Full text and rfc822 format available.

Message #48 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Boruch Baum <boruch_baum <at> gmx.com>
Cc: 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Thu, 06 May 2021 10:17:01 +0200
Boruch Baum <boruch_baum <at> gmx.com> writes:

>> So I fixed that up, but I've seen that in other patches -- could you
>> have a look and see what's causing this mixture of tab and spaces?
>
> I could use a suggestion to automate that workflow: I never use tabs,
> but often find myself editing files that have them. As soon as it gets
> annoying, I remember to perform untabify on the buffer, but there's
> probably an accepted automated method to respect the tab/space
> preferences of everyone.

With the default Emacs settings, you should never end up with a space
before a tab -- have you perhaps customised what the TAB key does here?
In general, the default TAB function tries to respect the indentation
style.  (But it'll never insert a space before a tab.)

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Thu, 06 May 2021 10:17:01 GMT) Full text and rfc822 format available.

Message #51 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Boruch Baum <boruch_baum <at> gmx.com>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Thu, 6 May 2021 06:16:15 -0400
On 2021-05-06 10:17, Lars Ingebrigtsen wrote:
> Boruch Baum <boruch_baum <at> gmx.com> writes:
>
> >> So I fixed that up, but I've seen that in other patches -- could you
> >> have a look and see what's causing this mixture of tab and spaces?
> >
> > I could use a suggestion to automate that workflow: I never use tabs,
> > but often find myself editing files that have them. As soon as it gets
> > annoying, I remember to perform untabify on the buffer, but there's
> > probably an accepted automated method to respect the tab/space
> > preferences of everyone.
>
> With the default Emacs settings, you should never end up with a space
> before a tab -- have you perhaps customised what the TAB key does here?
> In general, the default TAB function tries to respect the indentation
> style.  (But it'll never insert a space before a tab.)

But I don't ever want a tab, ever, in any document that I work on, ever.
If tabs are needed in order to be compatible with upstream then I'd want
emacs to untabify on read and tabify on export.

--
hkp://keys.gnupg.net
CA45 09B5 5351 7C11 A9D1  7286 0036 9E45 1595 8BC0




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Thu, 06 May 2021 11:06:02 GMT) Full text and rfc822 format available.

Message #54 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Boruch Baum <boruch_baum <at> gmx.com>
To: Robert Pluim <rpluim <at> gmail.com>
Cc: Eli Zaretskii <eliz <at> gnu.org>, larsi <at> gnus.org, 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Thu, 6 May 2021 07:05:15 -0400
On 2021-05-06 10:10, Robert Pluim wrote:
> From NEWS.27:
> ...

Thanks, Robert! Very helpful pointers. And now that debian has finally
bumped me to version 27.1, I really should read that NEWS file ...

--
hkp://keys.gnupg.net
CA45 09B5 5351 7C11 A9D1  7286 0036 9E45 1595 8BC0




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#47784; Package emacs. (Fri, 07 May 2021 11:15:01 GMT) Full text and rfc822 format available.

Message #57 received at 47784 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Boruch Baum <boruch_baum <at> gmx.com>
Cc: 47784 <at> debbugs.gnu.org
Subject: Re: bug#47784: 27.2: ses-header-row [PATCH INCLUDED]
Date: Fri, 07 May 2021 13:14:03 +0200
Boruch Baum <boruch_baum <at> gmx.com> writes:

> But I don't ever want a tab, ever, in any document that I work on, ever.

That's counter to how Emacs sources are (and should remain).  We use a
mix of tabs and spaces (but the spaces are after the tabs).

> If tabs are needed in order to be compatible with upstream then I'd want
> emacs to untabify on read and tabify on export.

I don't think there's any such functionality in Emacs, but it shouldn't
be difficult for you to hack up something like that to fix up your
patches.  It would be easier if you just didn't change your tab/space
settings when you work on Emacs sources, though.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Fri, 04 Jun 2021 11:24:06 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 298 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.