From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dmitry Newsgroups: gmane.emacs.bugs Subject: bug#17978: 24.3; forward-paragraph broken with javadocs Date: Fri, 11 Jul 2014 09:54:45 +0300 Message-ID: <864myoe66i.fsf@yandex.ru> References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1405061725 24158 80.91.229.3 (11 Jul 2014 06:55:25 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 11 Jul 2014 06:55:25 +0000 (UTC) Cc: Justine Tunney , 17978@debbugs.gnu.org To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Jul 11 08:55:18 2014 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1X5Ujl-0005ms-U9 for geb-bug-gnu-emacs@m.gmane.org; Fri, 11 Jul 2014 08:55:18 +0200 Original-Received: from localhost ([::1]:42529 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X5Ujl-0008Uu-Js for geb-bug-gnu-emacs@m.gmane.org; Fri, 11 Jul 2014 02:55:17 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50106) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X5Ujd-0008Tm-8O for bug-gnu-emacs@gnu.org; Fri, 11 Jul 2014 02:55:15 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1X5UjX-0008IV-CV for bug-gnu-emacs@gnu.org; Fri, 11 Jul 2014 02:55:09 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:38021) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X5UjX-0008Hi-80 for bug-gnu-emacs@gnu.org; Fri, 11 Jul 2014 02:55:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1X5UjW-00032U-Fj for bug-gnu-emacs@gnu.org; Fri, 11 Jul 2014 02:55:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 11 Jul 2014 06:55:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 17978 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 17978-submit@debbugs.gnu.org id=B17978.140506170011670 (code B ref 17978); Fri, 11 Jul 2014 06:55:02 +0000 Original-Received: (at 17978) by debbugs.gnu.org; 11 Jul 2014 06:55:00 +0000 Original-Received: from localhost ([127.0.0.1]:52820 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1X5UjT-00032A-GD for submit@debbugs.gnu.org; Fri, 11 Jul 2014 02:54:59 -0400 Original-Received: from mail-wi0-f172.google.com ([209.85.212.172]:57566) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1X5UjR-00031n-Tg for 17978@debbugs.gnu.org; Fri, 11 Jul 2014 02:54:58 -0400 Original-Received: by mail-wi0-f172.google.com with SMTP id hi2so5720467wib.5 for <17978@debbugs.gnu.org>; Thu, 10 Jul 2014 23:54:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type; bh=u8VRvkYwfOVs5ZJHw1EGOqtVHBGFtJn2arA1QA5iwzQ=; b=yGzoyIwQ+e7rjegnPgUG47wNjqrOrSxHY8ghvQH8fQ5oNOL/tAtTZdRSh7AO3Zv9Ar aQC7IJNOkpnaf/oIlB4lEnOExrWbsJzDB4GyrOEpbhACBJC0/hcTa5kh0un/0lAqf9BY uqqmxlaPdzQyoqmHpKx27yyQ07W6wL42YiPtcMenrHlYCvwR19ehg/mwDiJsCAVnulCv wf4egOVvFbYB10/mn7+NoJ5cYez/Mw7H8exfpyXJY+Y2dAgI86iaMOmbqJfsCs6bBBnw UYSEtNzq3GIWU28yd10yCL1w2oaxpiWeQ0ZjXehK5IBCtnuMvWEXW0O0781orSMITcum dhYA== X-Received: by 10.180.103.228 with SMTP id fz4mr2632822wib.4.1405061689708; Thu, 10 Jul 2014 23:54:49 -0700 (PDT) Original-Received: from axl (v-2-eu19-d3962-07.webazilla.com. [78.140.151.7]) by mx.google.com with ESMTPSA id nc19sm4003098wic.4.2014.07.10.23.54.47 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Thu, 10 Jul 2014 23:54:48 -0700 (PDT) In-Reply-To: (Stefan Monnier's message of "Wed, 09 Jul 2014 23:06:57 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.92 (gnu/linux) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:91428 Archived-At: Stefan Monnier writes: >> C-{ and C-} should cycle between blank lines. But the reason why this >> doesn't happen in java-mode, is because Java redefines the definition of a >> paragraph. It sets the paragraph-start variable (among other variables) so >> that when I M-q to fill-paragraph, it'll work correctly *within* the >> Javadoc, rather than reflowing my code into a jumbled mess. > Hi Stefan, > Ah, I see, yes, that makes sense. The fix is to not change > paragraph-start (and friends) in the major-mode hook but instead to > define override the fill-forward-paragraph-function with a function > which let-binds those vars and then calls forward-paragraph. Thanks for the vertict, I'll fix that in js2-mode, This doesn't look straightforward to do, though: the final `paragraph-start' is obtained by calling `c-setup-paragraph-variables', so to get the value computed both ways, guess we'll have to call it at least twice.