unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Kazuhiro Ito <kzhr@d1.dion.ne.jp>
To: 7596@debbugs.gnu.org
Subject: bug#7596: 23.2.90; fill-flowed with DELETE-SPACE option does not work
Date: Thu, 09 Dec 2010 08:48:00 +0900	[thread overview]
Message-ID: <82bp4vn7wv.wl%kzhr@d1.dion.ne.jp> (raw)

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

When I start emacs (emacs-23 branch) with -Q and evaluate below code,
I receive unexpected result.

(with-temp-buffer
  (insert "ABC \nDEF")
  (fill-flowed nil t)
  (buffer-string))

It returns 

"ABC
DEF"

But I expect 

"ABCDEF"


I expect DELETE-SPACE option corresponds to "DelSp" parameter in
RFC3676 and works so.  Plesse see attached patch.

-- 
Kazuhiro Ito

[-- Attachment #2: flow-fill.el.diff --]
[-- Type: application/octet-stream, Size: 654 bytes --]

=== modified file 'lisp/gnus/flow-fill.el'
--- lisp/gnus/flow-fill.el	2010-01-13 08:35:10 +0000
+++ lisp/gnus/flow-fill.el	2010-12-08 10:14:13 +0000
@@ -106,8 +106,6 @@
       (forward-line 1))
     (goto-char (point-min))
     (while (re-search-forward " $" nil t)
-      (when delete-space
-	(delete-char -1))
       (when (save-excursion
 	      (beginning-of-line)
 	      (looking-at "^\\(>*\\)\\( ?\\)"))
@@ -135,6 +133,8 @@
 	      (replace-match (if (string= (match-string 2) " ")
 				 "" "\\2")))
 	    (backward-delete-char -1)
+	    (when delete-space
+	      (delete-char -1))
 	    (end-of-line))
 	  (unless sig
 	    (condition-case nil


             reply	other threads:[~2010-12-08 23:48 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-08 23:48 Kazuhiro Ito [this message]
2011-01-22 19:31 ` bug#7596: 23.2.90; fill-flowed with DELETE-SPACE option does not work Chong Yidong
     [not found] ` <877hdwzqdz.fsf@stupidchicken.com>
2011-01-22 19:48   ` Lars Ingebrigtsen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=82bp4vn7wv.wl%kzhr@d1.dion.ne.jp \
    --to=kzhr@d1.dion.ne.jp \
    --cc=7596@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).