GNU bug report logs - #13740
About a coding convention

Previous Next

Package: emacs;

Reported by: Xue Fuqiao <xfq.free <at> gmail.com>

Date: Mon, 18 Feb 2013 00:27:02 UTC

Severity: wishlist

Done: Stefan Kangas <stefan <at> marxist.se>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Xue Fuqiao <xfq.free <at> gmail.com>
Subject: bug#13740: closed (Re: bug#13740: About a coding convention)
Date: Fri, 07 Aug 2020 11:24:02 +0000
[Message part 1 (text/plain, inline)]
Your bug report

#13740: About a coding convention

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to 13740 <at> debbugs.gnu.org.

-- 
13740: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=13740
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Stefan Kangas <stefan <at> marxist.se>
To: Glenn Morris <rgm <at> gnu.org>
Cc: Xue Fuqiao <xfq.free <at> gmail.com>, 13740-done <at> debbugs.gnu.org
Subject: Re: bug#13740: About a coding convention
Date: Fri, 7 Aug 2020 04:23:22 -0700
Glenn Morris <rgm <at> gnu.org> writes:

> Xue Fuqiao wrote:
>
>> 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'.
>
> I don't think it is useful to list pre-existing exceptions to a general
> guideline.

Agreed.  Since no one else has voiced an opinion, I'm therefore closing
this bug report.

Best regards,
Stefan Kangas

[Message part 3 (message/rfc822, inline)]
From: Xue Fuqiao <xfq.free <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: About a coding convention
Date: Mon, 18 Feb 2013 08:25:15 +0800
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.

-- 
Best regards, Xue Fuqiao.
http://www.emacswiki.org/emacs/XueFuqiao



This bug report was last modified 4 years and 290 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.