From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Teemu Likonen Newsgroups: gmane.emacs.bugs Subject: bug#1756: awk-mode: An empty line is not a paragraph separator (should be) Date: Thu, 01 Jan 2009 10:27:17 +0200 Message-ID: <87sko35t3u.fsf@iki.fi> Reply-To: Teemu Likonen , 1756@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1230799420 22490 80.91.229.12 (1 Jan 2009 08:43:40 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 1 Jan 2009 08:43:40 +0000 (UTC) To: bug-gnu-emacs@gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Jan 01 09:44:49 2009 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1LIJAe-00035L-6h for geb-bug-gnu-emacs@m.gmane.org; Thu, 01 Jan 2009 09:44:48 +0100 Original-Received: from localhost ([127.0.0.1]:43669 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LIJ9P-0005qh-BK for geb-bug-gnu-emacs@m.gmane.org; Thu, 01 Jan 2009 03:43:31 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LIJ9L-0005p6-Ap for bug-gnu-emacs@gnu.org; Thu, 01 Jan 2009 03:43:27 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LIJ9J-0005nH-DC for bug-gnu-emacs@gnu.org; Thu, 01 Jan 2009 03:43:27 -0500 Original-Received: from [199.232.76.173] (port=57787 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LIJ9J-0005n3-7n for bug-gnu-emacs@gnu.org; Thu, 01 Jan 2009 03:43:25 -0500 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:58141) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1LIJ9I-0004XP-Hj for bug-gnu-emacs@gnu.org; Thu, 01 Jan 2009 03:43:24 -0500 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n018hMbe005751; Thu, 1 Jan 2009 00:43:22 -0800 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.13.8/8.13.8/Submit) id n018Z4am003482; Thu, 1 Jan 2009 00:35:04 -0800 X-Loop: owner@emacsbugs.donarmstrong.com Resent-From: Teemu Likonen Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Thu, 01 Jan 2009 08:35:04 +0000 Resent-Message-ID: Resent-Sender: owner@emacsbugs.donarmstrong.com X-Emacs-PR-Message: report 1756 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by submit@emacsbugs.donarmstrong.com id=B.12307984502032 (code B ref -1); Thu, 01 Jan 2009 08:35:04 +0000 Original-Received: (at submit) by emacsbugs.donarmstrong.com; 1 Jan 2009 08:27:30 +0000 X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. Original-Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n018RQk9002026 for ; Thu, 1 Jan 2009 00:27:28 -0800 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LIItq-0007Vp-2n for bug-gnu-emacs@gnu.org; Thu, 01 Jan 2009 03:27:26 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LIIto-0007Vd-OU for bug-gnu-emacs@gnu.org; Thu, 01 Jan 2009 03:27:25 -0500 Original-Received: from [199.232.76.173] (port=57414 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LIIto-0007Va-Es for bug-gnu-emacs@gnu.org; Thu, 01 Jan 2009 03:27:24 -0500 Original-Received: from mta-out.inet.fi ([195.156.147.13]:35318 helo=jenni1.inet.fi) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LIItn-0002oM-Qi for bug-gnu-emacs@gnu.org; Thu, 01 Jan 2009 03:27:24 -0500 Original-Received: from mithlond.arda.local (80.220.180.181) by jenni1.inet.fi (8.5.014) id 48FC59C70333947E for bug-gnu-emacs@gnu.org; Thu, 1 Jan 2009 10:27:22 +0200 Original-Received: from dtw by mithlond.arda.local with local (Exim 4.69) (envelope-from ) id 1LIIth-0000uU-Vn for bug-gnu-emacs@gnu.org; Thu, 01 Jan 2009 10:27:18 +0200 User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.2 (gnu/linux) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) Resent-Date: Thu, 01 Jan 2009 03:43:27 -0500 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:23644 Archived-At: In awk-mode an empty line is not considered a paragraph separator, only lines containing whitespace and "#" character(s) are. After running the command "M-x awk-mode" the value of both paragraph-start and paragraph-separate are set as follows: "[ \t]*\\(#+\\)[ \t]*$\\|^\f" ^^ See, at least one # is required. I think better default would be #* so that empty lines or lines with only whitespace would be paragraph separators too. I suggest doing the following change: diff --git i/lisp/progmodes/cc-vars.el w/lisp/progmodes/cc-vars.el index 18f314c..62c85f0 100644 --- i/lisp/progmodes/cc-vars.el +++ w/lisp/progmodes/cc-vars.el @@ -483,7 +483,7 @@ style comments." (defcustom-c-stylevar c-comment-prefix-regexp '((pike-mode . "//+!?\\|\\**") - (awk-mode . "#+") + (awk-mode . "#*") (other . "//+\\|\\**")) "*Regexp to match the line prefix inside comments. This regexp is used to recognize the fill prefix inside comments for (pike-mode and "other" have a comment prefix regexp which matches a zero number of comment prefix characters: \**) There is another and related bug. It is possible to configure the comment prefix regexp with the option c-comment-prefix-regexp. But the problem is that the option only takes effect when awk-mode is turned on. If user later changes indentation style with the command c-set-style (bound to C-c .) then it seems that the hard-coded default (#+) takes preference over user's c-comment-prefix-regexp settings.