unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: "Drew Adams" <drew.adams@oracle.com>
To: "'Chong Yidong'" <cyd@gnu.org>
Cc: 8638@debbugs.gnu.org
Subject: bug#8638: 24.0.50; Imenu should not include vacuous defvars
Date: Sun, 5 Aug 2012 20:52:18 -0700	[thread overview]
Message-ID: <D97E49D976844FDAA0CE033099A0FB48@us.oracle.com> (raw)
In-Reply-To: <87hasgr8h7.fsf@gnu.org>

> > OK, thanks.  But I wonder why you treated defvar differently from
> > defconst, defconstant, defcustom, defparameter, and
> > define-symbol-macro here.  Shouldn't the same thing apply to them?
> 
> There is no such thing as (defconst foo), or (defcustom foo); 
> the second argument is non-optional.

Yes, I know.

> So the reasoning which was used for defvar, i.e. that a defvar
> with an omitted second arg is commonly used just to silence the
> compiler, does not apply.

But the reasoning that such things, if they ever occurred, would not represent
proper definitions, so Imenu should not index them, holds.  They would represent
incorrect syntax (i.e., errors), and should not be indexed.

Anyway, I'm OK with them being falsely indexed, and I would agree if you made
the argument that we do not try to prevent indexing of incorrect syntax in
general.
 






  reply	other threads:[~2012-08-06  3:52 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-08 18:15 bug#8638: 24.0.50; Imenu should not include vacuous defvars Drew Adams
2011-05-08 18:50 ` Juanma Barranquero
2011-05-08 19:07   ` Drew Adams
2011-05-08 19:25     ` Juanma Barranquero
2011-05-08 19:36       ` Drew Adams
2011-05-08 19:46         ` Juanma Barranquero
2011-05-08 19:46           ` Juanma Barranquero
2011-05-08 20:03           ` Drew Adams
2011-05-08 20:29             ` Juanma Barranquero
2011-05-08 20:39               ` Drew Adams
2011-05-08 20:52                 ` Juanma Barranquero
2011-05-08 21:49                   ` Drew Adams
2011-05-27 16:00     ` Drew Adams
2012-08-05 14:15       ` Chong Yidong
2012-08-05 16:27         ` Drew Adams
2012-08-06  3:43           ` Chong Yidong
2012-08-06  3:52             ` Drew Adams [this message]
2011-05-09 14:19   ` Stefan Monnier
2011-05-09 14:31     ` Juanma Barranquero

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=D97E49D976844FDAA0CE033099A0FB48@us.oracle.com \
    --to=drew.adams@oracle.com \
    --cc=8638@debbugs.gnu.org \
    --cc=cyd@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).