From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#24038: etags missing tag for static prototypes in header file Date: Thu, 21 Jul 2016 17:51:17 +0300 Message-ID: <83y44vxcwq.fsf@gnu.org> References: <6bf5b612.9f65.156088809dd.Coremail.moan1223@163.com> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=gbk Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1469114079 27561 80.91.229.3 (21 Jul 2016 15:14:39 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 21 Jul 2016 15:14:39 +0000 (UTC) Cc: 24038@debbugs.gnu.org To: 312 Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Jul 21 17:14:28 2016 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 1bQFgB-0003fe-Ny for geb-bug-gnu-emacs@m.gmane.org; Thu, 21 Jul 2016 17:14:27 +0200 Original-Received: from localhost ([::1]:41439 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bQFgA-0005bX-IL for geb-bug-gnu-emacs@m.gmane.org; Thu, 21 Jul 2016 11:14:26 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:44773) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bQFKX-00033Y-RB for bug-gnu-emacs@gnu.org; Thu, 21 Jul 2016 10:52:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bQFKU-0008PV-5V for bug-gnu-emacs@gnu.org; Thu, 21 Jul 2016 10:52:04 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:48235) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bQFKU-0008PP-20 for bug-gnu-emacs@gnu.org; Thu, 21 Jul 2016 10:52:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1bQFKT-0000ue-Su for bug-gnu-emacs@gnu.org; Thu, 21 Jul 2016 10:52:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 21 Jul 2016 14:52:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 24038 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 24038-submit@debbugs.gnu.org id=B24038.14691126823462 (code B ref 24038); Thu, 21 Jul 2016 14:52:01 +0000 Original-Received: (at 24038) by debbugs.gnu.org; 21 Jul 2016 14:51:22 +0000 Original-Received: from localhost ([127.0.0.1]:60572 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bQFJq-0000tl-1s for submit@debbugs.gnu.org; Thu, 21 Jul 2016 10:51:22 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:53460) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bQFJo-0000tY-Ao for 24038@debbugs.gnu.org; Thu, 21 Jul 2016 10:51:20 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bQFJf-0008EV-7B for 24038@debbugs.gnu.org; Thu, 21 Jul 2016 10:51:15 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:49638) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bQFJf-0008EQ-3w; Thu, 21 Jul 2016 10:51:11 -0400 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:4931 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1bQFJe-000537-6w; Thu, 21 Jul 2016 10:51:10 -0400 In-reply-to: <6bf5b612.9f65.156088809dd.Coremail.moan1223@163.com> (message from 312 on Wed, 20 Jul 2016 21:39:08 +0800 (GMT+08:00)) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.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" Xref: news.gmane.org gmane.emacs.bugs:121390 Archived-At: > Date: Wed, 20 Jul 2016 21:39:08 +0800 (GMT+08:00) > From: 312 > > I found etags fails to create some tags for static method in header file. Is this a known issue. > > for example: > > etags NestedNameSpecifier.h > > lines between 100 and 162 is ignored, those are all static prototype. > Don¡¯t know why this happened. Thank you for your report. What is ignored are not static methods, but any method that is not in-line, i.e. for which you have only the declaration (a.k.a. "prototype") in the header file, without the implementation. For example, this method is also missing: /// \brief Determine what kind of nested name specifier is stored. SpecifierKind getKind() const; although it isn't declared 'static'. The reason is that etags by default doesn't tag declarations, on the assumption that the user wants to see the definitions of the methods, not their prototypes. If you want declarations included, you need to invoke etags with the --declarations option. (That will also tag global variables, so if you don't want that, use --no-globals as well.) IOW, this is not a bug, but the expected behavior.