From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#47408: Fwd: bug#47408: Etags support for Mercury [v0.4] Date: Sat, 29 May 2021 11:01:01 +0300 Message-ID: <838s3y6kaq.fsf@gnu.org> References: <70503251-f8ea-9006-b7e7-b13b93bb71de@gmail.com> <838s4gxurw.fsf@gnu.org> <53162dfb-0715-3077-78d1-3a8340943f2f@gmail.com> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="30908"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 47408@debbugs.gnu.org To: fabrice nicol Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat May 29 10:02:13 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lmtv9-0007lh-L3 for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 29 May 2021 10:02:11 +0200 Original-Received: from localhost ([::1]:46336 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lmtv8-00012l-Fw for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 29 May 2021 04:02:10 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:53448) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lmtv0-000114-51 for bug-gnu-emacs@gnu.org; Sat, 29 May 2021 04:02:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:44364) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lmtuz-0001A3-Qs for bug-gnu-emacs@gnu.org; Sat, 29 May 2021 04:02:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lmtuz-0006Fu-Ob for bug-gnu-emacs@gnu.org; Sat, 29 May 2021 04:02: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: Sat, 29 May 2021 08:02:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 47408 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 47408-submit@debbugs.gnu.org id=B47408.162227526323980 (code B ref 47408); Sat, 29 May 2021 08:02:01 +0000 Original-Received: (at 47408) by debbugs.gnu.org; 29 May 2021 08:01:03 +0000 Original-Received: from localhost ([127.0.0.1]:55910 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lmtu3-0006Ei-97 for submit@debbugs.gnu.org; Sat, 29 May 2021 04:01:03 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:59578) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lmtu0-0006E6-8o for 47408@debbugs.gnu.org; Sat, 29 May 2021 04:01:02 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:38066) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lmttu-0000CX-WB; Sat, 29 May 2021 04:00:55 -0400 Original-Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:3180 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lmtts-0006bJ-Fq; Sat, 29 May 2021 04:00:54 -0400 In-Reply-To: <53162dfb-0715-3077-78d1-3a8340943f2f@gmail.com> (message from fabrice nicol on Sat, 15 May 2021 12:19:26 +0200) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:207514 Archived-At: [Please use Reply All to have the bug address on the CC list.] > From: fabrice nicol > Date: Sat, 15 May 2021 12:19:26 +0200 > > The confusion stems from an earlier discussion with a third party (I > forgot his name), who proposed to reuse '--no-defines' **and** > '--declarations' to replace Mercury-specific short options that I had > introduced. You followed this advice and so did I except for one detail > that I will outline below. > > To make things clearer, I will rephrase the way I implemented this: > > 1. There are **no longer** Mercury-specific short options -m/-M. > > 2. As advised by this third party and your review comments, > '--declarations' is implemented in a Mercury-specific way (hence the - > correct - NEWS item about it, as well as a couple of sentences in the > man page, this is just what your review advised). > > Using '--declarations', etags will tag not only Mercury language > declarations (strictly speaking) but also 'legacy declarations', i.e. > the old Prolog way (in actual terms, these are definitions in Mercury, > but there is unfortunately no '--definitions' etags options, so we must > do with what we have in store). OK. But the documentation patches you submitted seem to be somewhat confusing: will Mercury declarations be tagged by default, or only when --declarations is used? This option isn't the default in etags, so either the declarations are tagged by default (i.e. without using this option) or only when --declarations is specified on the command line. You seem to say both, which I don't understand. And I have several minor comments to the patch: > +In Mercury, declarations start a line with "\|\fB:-\fP\|" and are tagged > +by default. Here, this is the confusing part about tagging Mercury declarations. > ++++ > +** Etags support for the Mercury programming language (https://mercurylang.org). > +** Etags command line option --declarations now has Mercury-specific behavior. > +All Mercury declarations are tagged by default. > +For compatibility with Prolog etags support, predicates and functions appearing > +first in clauses will also be tagged if etags is run with '--declarations'. And this as well. It leaves me wondering what is the difference between the results when using --declarations and not using it. > --- /dev/null > +++ b/lib-src/ChangeLog We don't maintain ChangeLog files anymore in the repository, so what you wanted to say there should be instead in the commit log message (which you didn't include). See CONTRIBUTE for more details about formatting commit log messages. > + /* Disambiguate file names between Objc and Mercury */ > + if (lang != NULL && strcmp(lang->name, "objc") == 0) > + test_objc_is_mercury(curfdp->infname, &lang); Our C style conventions are to leave one space between the function's name and the left parenthesis following it, as below: if (lang != NULL && strcmp (lang->name, "objc") == 0) test_objc_is_mercury (curfdp->infname, &lang); Please make sure you use this style everywhere. > diff --git a/test/manual/etags/merc-src/array.m b/test/manual/etags/merc-src/array.m > new file mode 100644 > index 0000000000..0663c41087 > --- /dev/null > +++ b/test/manual/etags/merc-src/array.m > @@ -0,0 +1,3416 @@ > +%---------------------------------------------------------------------------% > +% vim: ft=mercury ts=4 sw=4 et > +%---------------------------------------------------------------------------% > +% Copyright (C) 1993-1995, 1997-2012 The University of Melbourne. > +% Copyright (C) 2013-2018 The Mercury team. > +% This file is distributed under the terms specified in COPYING.LIB. Adding test file(s) for Mercury is great, but we cannot have there files under arbitrary license/copyright. If COPYING.LIB mentioned above specifies GPL or a compatible license, then it's okay for us to distribute this file, but we need a copy of that COPYING.LIB file as well. If the license is not compatible with GPL, we cannot distribute this file; in that case, please find some other test file, or provide your own. Thanks.