From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Xue Fuqiao Newsgroups: gmane.emacs.bugs Subject: bug#13740: About a coding convention Date: Thu, 21 Feb 2013 08:28:57 +0800 Organization: The Church of Emacs Message-ID: <20130221082857.3ad60989ae6f64d91b90bd42@gmail.com> References: <20130218082515.6ed5dfd2988fa1090af99a10@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1361406594 18219 80.91.229.3 (21 Feb 2013 00:29:54 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 21 Feb 2013 00:29:54 +0000 (UTC) Cc: 13740@debbugs.gnu.org To: Glenn Morris Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Feb 21 01:30:16 2013 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 1U8K3C-0003x0-Eh for geb-bug-gnu-emacs@m.gmane.org; Thu, 21 Feb 2013 01:30:14 +0100 Original-Received: from localhost ([::1]:44623 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U8K2s-0001iT-2R for geb-bug-gnu-emacs@m.gmane.org; Wed, 20 Feb 2013 19:29:54 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:59731) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U8K2o-0001iM-Mv for bug-gnu-emacs@gnu.org; Wed, 20 Feb 2013 19:29:52 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1U8K2n-0003TJ-AS for bug-gnu-emacs@gnu.org; Wed, 20 Feb 2013 19:29:50 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:35348) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U8K2n-0003Sh-4w for bug-gnu-emacs@gnu.org; Wed, 20 Feb 2013 19:29:49 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1U8K3y-0006GS-Dp for bug-gnu-emacs@gnu.org; Wed, 20 Feb 2013 19:31:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Xue Fuqiao Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 21 Feb 2013 00:31:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13740 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 13740-submit@debbugs.gnu.org id=B13740.136140661924024 (code B ref 13740); Thu, 21 Feb 2013 00:31:02 +0000 Original-Received: (at 13740) by debbugs.gnu.org; 21 Feb 2013 00:30:19 +0000 Original-Received: from localhost ([127.0.0.1]:40810 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U8K3H-0006FR-1X for submit@debbugs.gnu.org; Wed, 20 Feb 2013 19:30:19 -0500 Original-Received: from mail-pa0-f41.google.com ([209.85.220.41]:64832) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U8K3E-0006FJ-DV for 13740@debbugs.gnu.org; Wed, 20 Feb 2013 19:30:17 -0500 Original-Received: by mail-pa0-f41.google.com with SMTP id fb11so4345335pad.14 for <13740@debbugs.gnu.org>; Wed, 20 Feb 2013 16:29:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:date:from:to:cc:subject:message-id:in-reply-to :references:organization:x-mailer:mime-version:content-type :content-transfer-encoding; bh=T5L1vjMOGWR8zSaZ+nj2oUa/AmFWN4+xw3gu/7hC01E=; b=hu0Ze26mQSr5FG7fJDHt6bR+/os7FwEPBupoONl+cEdgrhYjmFqJegJ0rB1Wr6dYoE hXGQ+82MoihTjVi2/l2kHR6qF+TjbJRWe5UJyiLad9tgD8pCoAuTRSpQG8zkBDKDC0aK seDTLKwg5qK6dOoYru6w8DZYAO3J3+2rXFKPtJkpbOy1fEdXJZlGa2ixAS+S2mSD5rs4 bAu26g9RnQSgUHAttZr+QstB6zs3BlMkjHxtWjO7KriDx/633xr4edcxZiOi/A7CNYrb DUiDgMHLsWfv4x9VGxKEyWsCAJR1Qv7A+vCjGwtwg3kPyEFOy1e8/Ib54WFFWI0Ha/ip Slyg== X-Received: by 10.66.25.105 with SMTP id b9mr51367568pag.45.1361406541900; Wed, 20 Feb 2013 16:29:01 -0800 (PST) Original-Received: from Emacs ([219.224.52.162]) by mx.google.com with ESMTPS id y9sm112803293paw.1.2013.02.20.16.28.59 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 20 Feb 2013 16:29:00 -0800 (PST) In-Reply-To: X-Mailer: Sylpheed 3.2.0 (GTK+ 2.24.13; x86_64-pc-linux-gnu) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.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:71571 Archived-At: On Tue, 19 Feb 2013 14:55:35 -0500 Glenn Morris wrote: > Xue Fuqiao wrote: > > In (info "(elisp) Coding Conventions"): > > > > * Constructs that define a function or variable should be macros, > > not functions, and their names should start with `define-'. The > > macro should receive the name to be defined as the first argument. > > That will help various tools find the definition automatically. > > Avoid constructing the names in the macro itself, since that would > > confuse these tools. > > > > I think macros like `cl-defsubst', `cl-defun' should be mentioned here. > Why? They are macros that define functions, but they don't start with `define-'. > What would you say about them? Maybe something like this: Constructs that define a function or variable should be macros, not functions, and their names should start with `define-', except for some macros in `cl-lib', like `cl-defsubst' and `cl-defun'. -- Best regards, Xue Fuqiao. http://www.emacswiki.org/emacs/XueFuqiao