From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Bozhidar Batsov Newsgroups: gmane.emacs.devel Subject: Re: [Emacs-diffs] trunk r114939: * lisp/progmodes/ruby-mode.el (ruby-mode): Clean up docstring. Date: Mon, 4 Nov 2013 19:05:40 +0200 Message-ID: References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001a11c33676ffd15204ea5cec57 X-Trace: ger.gmane.org 1383584752 31986 80.91.229.3 (4 Nov 2013 17:05:52 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 4 Nov 2013 17:05:52 +0000 (UTC) Cc: emacs-devel To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Nov 04 18:05:57 2013 Return-path: Envelope-to: ged-emacs-devel@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 1VdNb6-0003WB-Rv for ged-emacs-devel@m.gmane.org; Mon, 04 Nov 2013 18:05:53 +0100 Original-Received: from localhost ([::1]:51126 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VdNb5-0005Me-Cj for ged-emacs-devel@m.gmane.org; Mon, 04 Nov 2013 12:05:51 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:60588) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VdNaw-0005MN-Rl for emacs-devel@gnu.org; Mon, 04 Nov 2013 12:05:47 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VdNav-0005uS-MX for emacs-devel@gnu.org; Mon, 04 Nov 2013 12:05:42 -0500 Original-Received: from mail-oa0-x236.google.com ([2607:f8b0:4003:c02::236]:40283) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VdNav-0005uE-HU for emacs-devel@gnu.org; Mon, 04 Nov 2013 12:05:41 -0500 Original-Received: by mail-oa0-f54.google.com with SMTP id o20so7478920oag.13 for ; Mon, 04 Nov 2013 09:05:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=pXGX3iLIR4N+YOBZZx5ZIfm6zL/iCSD9/FkzhqFZClI=; b=ngv6lZk8NIj0l7zCy4zK18dIMpflSMNzjchQSw5Jop6t9Cuw3hBzPWOTd7FPA2Go6m nF+JZ9NmQGFpOoJltXEsruqVjTYbFBsGRzAoYKXZLFdoI5vzovlO5S3nEx2kYQVe/3ll BkgMgeyUGVI98FiPeKK8grVYyD2MB5lsOvsWSf6r1n7rrTMpbuH6f/dnJDdIvyVR/fku v1FDpINh/F4PnSM+0z8J4DpeW0NQaewzejY25114IcOropoK+BrJBqsj6Ctj2fQJfAYp yQHPSNxAdO4y3BZ0tSz9MCTkGkc3HRe2ehqEzuIfdPqgJhVSBk0WvP8cF8Yl0WbU5dHb FeVw== X-Received: by 10.182.230.135 with SMTP id sy7mr14850503obc.24.1383584740907; Mon, 04 Nov 2013 09:05:40 -0800 (PST) Original-Received: by 10.76.131.116 with HTTP; Mon, 4 Nov 2013 09:05:40 -0800 (PST) In-Reply-To: X-Google-Sender-Auth: TmcgCYItW97PZyBDpVrZMBJ9tlg X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:4003:c02::236 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:164934 Archived-At: --001a11c33676ffd15204ea5cec57 Content-Type: text/plain; charset=UTF-8 This text should probably be removed from the description of other major modes as well, right? On 4 November 2013 19:04, Bozhidar Batsov wrote: > I didn't like this as well, but I added it since that exact text appears > in the docstrings of many major modes. I though it was something like an > unwritten convention, but I guess many people have simply been copy-pasting > the same code over the years. I'll have it removed. > > > On 4 November 2013 18:43, Stefan Monnier wrote: > >> > +Entry to this mode calls the value of `ruby-mode-hook' >> > +if that value is non-nil." >> >> That's problematic: >> - it's redundant since define-derived-mode already adds "In addition to >> any hooks its parent mode `prog-mode' might have run,\nthis mode runs >> the hook `ruby-mode-hook', as the final step\nduring initialization." >> - hooks aren't "called" but are "run". >> - it's not just "the value of `ruby-mode-hook'", but the *values*, since >> hooks use both the buffer-local and the global value of the symbol. >> - the hook is run even if it is nil (or unbound): running it will simply >> not do anything. >> >> >> Stefan >> > > --001a11c33676ffd15204ea5cec57 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
This text should probably be removed from the description = of other major modes as well, right?

On 4 November 2013 19:04, Bozhidar Batsov <= bozhidar@batsov.com> wrote:
I didn't like this as w= ell, but I added it since that exact text appears in the docstrings of many= major modes. I though it was something like an unwritten convention, but I= guess many people have simply been copy-pasting the same code over the yea= rs. =C2=A0I'll have it removed.


On 4 November= 2013 18:43, Stefan Monnier <monnier@iro.umontreal.ca> wrote:
> +Entry to this mode calls the value of = `ruby-mode-hook'
> +if that value is non-nil."

That's problematic:
- it's redundant since define-derived-mode already adds "In additi= on to
=C2=A0 any hooks its parent mode `prog-mode' might have run,\nthis mode= runs
=C2=A0 the hook `ruby-mode-hook', as the final step\nduring initializat= ion."
- hooks aren't "called" but are "run".
- it's not just "the value of `ruby-mode-hook'", but the = *values*, since
=C2=A0 hooks use both the buffer-local and the global value of the symbol.<= br> - the hook is run even if it is nil (or unbound): running it will simply =C2=A0 not do anything.


=C2=A0 =C2=A0 =C2=A0 =C2=A0 Stefan


--001a11c33676ffd15204ea5cec57--