unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#3033: 23.0.92; Try to auto fix whitespace loss? (y/n)
@ 2009-04-17 11:38 ` Leo
  2009-04-21  7:30   ` bug#3033: marked as done (23.0.92; Try to auto fix whitespace loss? (y/n)) Emacs bug Tracking System
  0 siblings, 1 reply; 7+ messages in thread
From: Leo @ 2009-04-17 11:38 UTC (permalink / raw)
  To: emacs-pretest-bug

[-- Attachment #1: Type: text/plain, Size: 398 bytes --]


When I try to open by drag and drop the attached file, Emacs keep asking
me 'Try to auto fix whitespace loss? (y/n)'. No matter y or n, the
dialogue will appear again and again until I kill the buffer.

I enable whitespace mode using (add-hook 'diff-mode-hook
'whitespace-mode).

GNU Emacs 23.0.92.1 (i386-apple-darwin9.6.0, NS apple-appkit-949.43) of
2009-04-15 on 64-71-7-214.static.wiline.com


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: emacs-gnus-ticked-doc.patch --]
[-- Type: text/x-patch, Size: 525 bytes --]

Index: gnus.texi
diff -u gnus/texi/gnus.texi:7.204 gnus/texi/gnus.texi:7.205
--- gnus.texi:7.204	Sat Dec 30 16:36:31 2006
+++ gnus.texi	Sat Dec 30 22:01:07 2006
@@ -10569,6 +10569,12 @@
 Pull all dormant articles (for the current group) into the summary buffer
 (@code{gnus-summary-insert-dormant-articles}).
 
+@item Y t
+@kindex Y t (Summary)
+@findex gnus-summary-insert-ticked-articles
+Pull all ticked articles (for the current group) into the summary buffer
+(@code{gnus-summary-insert-ticked-articles}).
+
 @end table

^ permalink raw reply	[flat|nested] 7+ messages in thread

* bug#3033: 23.0.92; Try to auto fix whitespace loss? (y/n)
@ 2009-04-18  1:55 Chong Yidong
  2009-04-18 13:24 ` Leo
  0 siblings, 1 reply; 7+ messages in thread
From: Chong Yidong @ 2009-04-18  1:55 UTC (permalink / raw)
  To: Leo; +Cc: 3033

> When I try to open by drag and drop the attached file, Emacs keep asking
> me 'Try to auto fix whitespace loss? (y/n)'. No matter y or n, the
> dialogue will appear again and again until I kill the buffer.
>
> I enable whitespace mode using (add-hook 'diff-mode-hook
> 'whitespace-mode).

I can't reproduce this.  Do you see the bug with a .emacs containing
only `(add-hook 'diff-mode-hook 'whitespace-mode)' and nothing else?






^ permalink raw reply	[flat|nested] 7+ messages in thread

* bug#3033: 23.0.92; Try to auto fix whitespace loss? (y/n)
  2009-04-18  1:55 bug#3033: 23.0.92; Try to auto fix whitespace loss? (y/n) Chong Yidong
@ 2009-04-18 13:24 ` Leo
  2009-04-20  7:58   ` martin rudalics
  0 siblings, 1 reply; 7+ messages in thread
From: Leo @ 2009-04-18 13:24 UTC (permalink / raw)
  To: bug-gnu-emacs

On 2009-04-18 02:55 +0100, Chong Yidong wrote:
>> When I try to open by drag and drop the attached file, Emacs keep asking
>> me 'Try to auto fix whitespace loss? (y/n)'. No matter y or n, the
>> dialogue will appear again and again until I kill the buffer.
>>
>> I enable whitespace mode using (add-hook 'diff-mode-hook
>> 'whitespace-mode).
>
> I can't reproduce this.  Do you see the bug with a .emacs containing
> only `(add-hook 'diff-mode-hook 'whitespace-mode)' and nothing else?

I have used edebug and error-on-quit to trace the culprit and find a
reproducible recipe. It turns out it has nothing to do with whitespace.

1. emacs -q
2. M-x which-func-mode
3. C-x C-f emacs-gnus-ticked-doc.patch

You should be able to see a dialogue pop up as in this screenshot
http://imagebin.org/46002.

In my experience, I have found which-func-mode to be intrusive and
unreliable. So I guess I will have to disable it to avoid further
trouble.

Best wishes,
-- 
.:  Leo  :.  [ sdl.web AT gmail.com ]  .: I use Emacs :.

               www.git-scm.com
    git - the one true version control system








^ permalink raw reply	[flat|nested] 7+ messages in thread

* bug#3033: 23.0.92; Try to auto fix whitespace loss? (y/n)
  2009-04-18 13:24 ` Leo
@ 2009-04-20  7:58   ` martin rudalics
  2009-04-20 15:53     ` Stefan Monnier
  2009-04-20 16:30     ` Leo
  0 siblings, 2 replies; 7+ messages in thread
From: martin rudalics @ 2009-04-20  7:58 UTC (permalink / raw)
  To: Leo, 3033

[-- Attachment #1: Type: text/plain, Size: 712 bytes --]

 > I have used edebug and error-on-quit to trace the culprit and find a
 > reproducible recipe. It turns out it has nothing to do with whitespace.
 >
 > 1. emacs -q
 > 2. M-x which-func-mode
 > 3. C-x C-f emacs-gnus-ticked-doc.patch
 >
[...]
 > In my experience, I have found which-func-mode to be intrusive and
 > unreliable. So I guess I will have to disable it to avoid further
 > trouble.

Looks to me like a bug in `diff-sanity-check-hunk' which fails to make
the hunk well-formed.  However, I think `diff-find-source-location'
shouldn't do any sanity checks in the first place when called with a
non-nil NOPROMPT argument.  So could you try whether the attached patch
solves your problem?

Thanks, martin.

[-- Attachment #2: diff-mode.el.diff --]
[-- Type: text/plain, Size: 1011 bytes --]

*** diff-mode.el.~1.157.~	2009-01-13 15:55:57.000000000 +0100
--- diff-mode.el	2009-04-20 09:39:22.515625000 +0200
***************
*** 1575,1581 ****
             ;; the user may disagree on what constitutes the hunk
             ;; (e.g. because an empty line truncates the hunk mid-course),
             ;; leading to potentially nasty surprises for the user.
!            (_ (diff-sanity-check-hunk))
  	   (hunk (buffer-substring
                    (point) (save-excursion (diff-end-of-hunk) (point))))
  	   (old (diff-hunk-text hunk reverse char-offset))
--- 1575,1581 ----
             ;; the user may disagree on what constitutes the hunk
             ;; (e.g. because an empty line truncates the hunk mid-course),
             ;; leading to potentially nasty surprises for the user.
!            (_ (unless noprompt (diff-sanity-check-hunk)))
  	   (hunk (buffer-substring
                    (point) (save-excursion (diff-end-of-hunk) (point))))
  	   (old (diff-hunk-text hunk reverse char-offset))

^ permalink raw reply	[flat|nested] 7+ messages in thread

* bug#3033: 23.0.92; Try to auto fix whitespace loss? (y/n)
  2009-04-20  7:58   ` martin rudalics
@ 2009-04-20 15:53     ` Stefan Monnier
  2009-04-20 16:30     ` Leo
  1 sibling, 0 replies; 7+ messages in thread
From: Stefan Monnier @ 2009-04-20 15:53 UTC (permalink / raw)
  To: martin rudalics; +Cc: Leo, 3033

> the hunk well-formed.  However, I think `diff-find-source-location'
> shouldn't do any sanity checks in the first place when called with a
> non-nil NOPROMPT argument.

Indeed, thank you,


        Stefan






^ permalink raw reply	[flat|nested] 7+ messages in thread

* bug#3033: 23.0.92; Try to auto fix whitespace loss? (y/n)
  2009-04-20  7:58   ` martin rudalics
  2009-04-20 15:53     ` Stefan Monnier
@ 2009-04-20 16:30     ` Leo
  1 sibling, 0 replies; 7+ messages in thread
From: Leo @ 2009-04-20 16:30 UTC (permalink / raw)
  To: martin rudalics; +Cc: 3033

2009/4/20 martin rudalics <rudalics@gmx.at>:
>> I have used edebug and error-on-quit to trace the culprit and find a
>> reproducible recipe. It turns out it has nothing to do with whitespace.
>>
>> 1. emacs -q
>> 2. M-x which-func-mode
>> 3. C-x C-f emacs-gnus-ticked-doc.patch
>>
> [...]
>> In my experience, I have found which-func-mode to be intrusive and
>> unreliable. So I guess I will have to disable it to avoid further
>> trouble.
>
> Looks to me like a bug in `diff-sanity-check-hunk' which fails to make
> the hunk well-formed.  However, I think `diff-find-source-location'
> shouldn't do any sanity checks in the first place when called with a
> non-nil NOPROMPT argument.  So could you try whether the attached patch
> solves your problem?
>
> Thanks, martin.

I tried the patch and it seems to work.

Thank you.

Leo






^ permalink raw reply	[flat|nested] 7+ messages in thread

* bug#3033: marked as done (23.0.92; Try to auto fix whitespace  loss? (y/n))
  2009-04-17 11:38 ` bug#3033: 23.0.92; Try to auto fix whitespace loss? (y/n) Leo
@ 2009-04-21  7:30   ` Emacs bug Tracking System
  0 siblings, 0 replies; 7+ messages in thread
From: Emacs bug Tracking System @ 2009-04-21  7:30 UTC (permalink / raw)
  To: martin rudalics

[-- Attachment #1: Type: text/plain, Size: 887 bytes --]


Your message dated Tue, 21 Apr 2009 09:18:50 +0200
with message-id <49ED735A.4030704@gmx.at>
and subject line Re: bug#3033: 23.0.92; Try to auto fix whitespace loss? (y/n)
has caused the Emacs bug report #3033,
regarding 23.0.92; Try to auto fix whitespace loss? (y/n)
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@emacsbugs.donarmstrong.com
immediately.)


-- 
3033: http://emacsbugs.donarmstrong.com/cgi-bin/bugreport.cgi?bug=3033
Emacs Bug Tracking System
Contact owner@emacsbugs.donarmstrong.com with problems

[-- Attachment #2: Type: message/rfc822, Size: 3299 bytes --]

[-- Attachment #2.1.1: Type: text/plain, Size: 398 bytes --]


When I try to open by drag and drop the attached file, Emacs keep asking
me 'Try to auto fix whitespace loss? (y/n)'. No matter y or n, the
dialogue will appear again and again until I kill the buffer.

I enable whitespace mode using (add-hook 'diff-mode-hook
'whitespace-mode).

GNU Emacs 23.0.92.1 (i386-apple-darwin9.6.0, NS apple-appkit-949.43) of
2009-04-15 on 64-71-7-214.static.wiline.com


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2.1.2: emacs-gnus-ticked-doc.patch --]
[-- Type: text/x-patch, Size: 525 bytes --]

Index: gnus.texi
diff -u gnus/texi/gnus.texi:7.204 gnus/texi/gnus.texi:7.205
--- gnus.texi:7.204	Sat Dec 30 16:36:31 2006
+++ gnus.texi	Sat Dec 30 22:01:07 2006
@@ -10569,6 +10569,12 @@
 Pull all dormant articles (for the current group) into the summary buffer
 (@code{gnus-summary-insert-dormant-articles}).
 
+@item Y t
+@kindex Y t (Summary)
+@findex gnus-summary-insert-ticked-articles
+Pull all ticked articles (for the current group) into the summary buffer
+(@code{gnus-summary-insert-ticked-articles}).
+
 @end table

[-- Attachment #3: Type: message/rfc822, Size: 1893 bytes --]

From: martin rudalics <rudalics@gmx.at>
To: Leo <sdl.web@googlemail.com>
Cc: 3033-done@emacsbugs.donarmstrong.com
Subject: Re: bug#3033: 23.0.92; Try to auto fix whitespace loss? (y/n)
Date: Tue, 21 Apr 2009 09:18:50 +0200
Message-ID: <49ED735A.4030704@gmx.at>

> I tried the patch and it seems to work.

Thanks for testing.  So this has been fixed as:

	* diff-mode.el (diff-find-source-location): Don't call
	diff-sanity-check-hunk when NOPROMPT is non-nil.  (Bug#3033)

martin



^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2009-04-21  7:30 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <49ED735A.4030704@gmx.at>
2009-04-17 11:38 ` bug#3033: 23.0.92; Try to auto fix whitespace loss? (y/n) Leo
2009-04-21  7:30   ` bug#3033: marked as done (23.0.92; Try to auto fix whitespace loss? (y/n)) Emacs bug Tracking System
2009-04-18  1:55 bug#3033: 23.0.92; Try to auto fix whitespace loss? (y/n) Chong Yidong
2009-04-18 13:24 ` Leo
2009-04-20  7:58   ` martin rudalics
2009-04-20 15:53     ` Stefan Monnier
2009-04-20 16:30     ` Leo

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).