From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 16 06:33:35 2015 Received: (at submit) by debbugs.gnu.org; 16 Feb 2015 11:33:35 +0000 Received: from localhost ([127.0.0.1]:45204 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YNJve-0004Zy-Ra for submit@debbugs.gnu.org; Mon, 16 Feb 2015 06:33:34 -0500 Received: from eggs.gnu.org ([208.118.235.92]:55029) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YNJvZ-0004Zg-3f for submit@debbugs.gnu.org; Mon, 16 Feb 2015 06:33:29 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YNJvP-0000oY-4J for submit@debbugs.gnu.org; Mon, 16 Feb 2015 06:33:19 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.2 required=5.0 tests=BAYES_40,DRUGS_MUSCLE autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:58615) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YNJvP-0000oM-1g for submit@debbugs.gnu.org; Mon, 16 Feb 2015 06:33:15 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56666) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YNJvJ-000168-4i for bug-gnu-emacs@gnu.org; Mon, 16 Feb 2015 06:33:15 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YNJvD-0000iV-7F for bug-gnu-emacs@gnu.org; Mon, 16 Feb 2015 06:33:09 -0500 Received: from mail-gw1-out.broadcom.com ([216.31.210.62]:64733) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YNJvD-0000ha-2U for bug-gnu-emacs@gnu.org; Mon, 16 Feb 2015 06:33:03 -0500 X-IronPort-AV: E=Sophos;i="5.09,587,1418112000"; d="scan'208";a="57376186" Received: from irvexchcas08.broadcom.com (HELO IRVEXCHCAS08.corp.ad.broadcom.com) ([10.9.208.57]) by mail-gw1-out.broadcom.com with ESMTP; 16 Feb 2015 05:57:59 -0800 Received: from IRVEXCHSMTP1.corp.ad.broadcom.com (10.9.207.51) by IRVEXCHCAS08.corp.ad.broadcom.com (10.9.208.57) with Microsoft SMTP Server (TLS) id 14.3.174.1; Mon, 16 Feb 2015 03:33:00 -0800 Received: from mail-irva-13.broadcom.com (10.10.10.20) by IRVEXCHSMTP1.corp.ad.broadcom.com (10.9.207.51) with Microsoft SMTP Server id 14.3.174.1; Mon, 16 Feb 2015 03:33:06 -0800 Received: from xl-cam-20.broadcom.com (xl-cam-20.cam.broadcom.com [10.177.132.80]) by mail-irva-13.broadcom.com (Postfix) with ESMTP id 6E0A440FEB for ; Mon, 16 Feb 2015 03:31:56 -0800 (PST) Received: by xl-cam-20.broadcom.com (Postfix, from userid 35990) id 2EE5018071E; Mon, 16 Feb 2015 11:32:59 +0000 (GMT) From: Rupert Swarbrick To: Subject: 25.0.50; Backwards font-lock regex in m4-mode Date: Mon, 16 Feb 2015 11:32:59 +0000 Message-ID: <889iof2rt04.fsf@broadcom.com> MIME-Version: 1.0 Content-Type: text/plain X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -2.5 (--) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.5 (--) In m4-mode.el, the last two sexps in m4-font-lock-keywords are the wrong way around. As a result, if you are writing M4 code to be expanded in "-P mode", so have things like m4_define in the file, then the "define" part gets matched by the penultimate regex, so m4_ doesn't get highlighted as part of a keyword. I think the fix for this is to just swap the two regexes around. That said, the commented stuff at the bottom of the file is rather ugly. Maybe it would be better to have a single regex, made with something like: (regexp-opt (append (mapcar (lambda (kw) (concat "m4_" kw)) prefixed) prefixed unprefixed)) with prefixed containing: '("builtin" "changecom" "changequote" "changeword" "debugfile" "debugmode" "decr" "define" "defn" "divert" "divnum" "dnl" "dumpdef" "errprint" "esyscmd" "eval" "file" "format" "ifdef" "ifelse" "include" "incr" "index" "indir" "len" "line" "m4exit" "m4wrap" "maketemp" "patsubst" "popdef" "pushdef" "regexp" "shift" "sinclude" "substr" "syscmd" "sysval" "traceoff" "traceon" "translit" "undefine" "undivert" "unix")) and unprefixed containing: '("gnu") Or maybe the absence of m4_gnu is a typo, in which case the logic could be slightly simpler. I'm assuming that "m4_m4_undefine" at the bottom of the file is a mistake. Sorry there's no patch: I've requested assignment papers, but they haven't come through yet. Since I think I've hit my minimal change limit, someone else gets to type the code... Rupert In GNU Emacs 25.0.50.1 (x86_64-unknown-linux-gnu, X toolkit, Xaw scroll bars) of 2015-02-09 on Repository revision: 2f7008715326a49770fcb82003ed78eab28c0626 Windowing system distributor `The X.Org Foundation', version 11.0.11300000 I'm trimming the rest of the build info because I'm pretty certain it's not relevant to this report and contains lots of internal company paths. From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 21 01:30:30 2016 Received: (at 19882) by debbugs.gnu.org; 21 Mar 2016 05:30:30 +0000 Received: from localhost ([127.0.0.1]:56125 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ahsQA-0006mY-N1 for submit@debbugs.gnu.org; Mon, 21 Mar 2016 01:30:30 -0400 Received: from mail.mojserwer.eu ([195.110.48.8]:35865) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ahsQ9-0006mM-8O for 19882@debbugs.gnu.org; Mon, 21 Mar 2016 01:30:29 -0400 Received: from localhost (localhost [127.0.0.1]) by mail.mojserwer.eu (Postfix) with ESMTP id 6C77BA3445F; Mon, 21 Mar 2016 06:30:26 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at mail.mojserwer.eu Received: from mail.mojserwer.eu ([127.0.0.1]) by localhost (mail.mojserwer.eu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Vj22kkdo3zRq; Mon, 21 Mar 2016 06:30:23 +0100 (CET) Received: from localhost (98-171.echostar.pl [213.156.98.171]) by mail.mojserwer.eu (Postfix) with ESMTPSA id CBF6CA3445E; Mon, 21 Mar 2016 06:30:23 +0100 (CET) From: Marcin Borkowski To: Rupert Swarbrick Subject: Re: bug#19882: 25.0.50; Backwards font-lock regex in m4-mode References: <889iof2rt04.fsf@broadcom.com> Date: Mon, 21 Mar 2016 06:30:20 +0100 In-Reply-To: <889iof2rt04.fsf@broadcom.com> (Rupert Swarbrick's message of "Mon, 16 Feb 2015 11:32:59 +0000") Message-ID: <87bn68e6tv.fsf@mbork.pl> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 1.8 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On 2015-02-16, at 11:32, Rupert Swarbrick wrote: > In m4-mode.el, the last two sexps in m4-font-lock-keywords are the wrong > way around. As a result, if you are writing M4 code to be expanded in > "-P mode", so have things like > > m4_define > > in the file, then the "define" part gets matched by the penultimate > regex, so m4_ doesn't get highlighted as part of a keyword. > > I think the fix for this is to just swap the two regexes around. That > said, the commented stuff at the bottom of the file is rather > ugly. Maybe it would be better to have a single regex, made with > something like: > > (regexp-opt (append (mapcar (lambda (kw) > (concat "m4_" kw)) > prefixed) > prefixed > unprefixed)) > > with prefixed containing: > > '("builtin" "changecom" "changequote" "changeword" "debugfile" > "debugmode" "decr" "define" "defn" "divert" "divnum" "dnl" > "dumpdef" "errprint" "esyscmd" "eval" "file" "format" > "ifdef" "ifelse" "include" "incr" "index" "indir" "len" "line" > "m4exit" "m4wrap" "maketemp" "patsubst" "popdef" "pushdef" "regexp" > "shift" "sinclude" "substr" "syscmd" "sysval" "traceoff" "traceon" > "translit" "undefine" "undivert" "unix")) > > > and unprefixed containing: > > '("gnu") > > > Or maybe the absence of m4_gnu is a typo, in which case the logic could > be slightly simpler. I'm assuming that "m4_m4_undefine" at the bottom of > the file is a mistake. > > Sorry there's no patch: I've requested assignment papers, but they > haven't come through yet. Since I think I've hit my minimal change > limit, someone else gets to type the code... [...] Content analysis details: (1.8 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [195.110.48.8 listed in list.dnswl.org] 2.5 DRUGS_MUSCLE Refers to a muscle relaxant X-Debbugs-Envelope-To: 19882 Cc: 19882@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 1.8 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On 2015-02-16, at 11:32, Rupert Swarbrick wrote: > In m4-mode.el, the last two sexps in m4-font-lock-keywords are the wrong > way around. As a result, if you are writing M4 code to be expanded in > "-P mode", so have things like > > m4_define > > in the file, then the "define" part gets matched by the penultimate > regex, so m4_ doesn't get highlighted as part of a keyword. > > I think the fix for this is to just swap the two regexes around. That > said, the commented stuff at the bottom of the file is rather > ugly. Maybe it would be better to have a single regex, made with > something like: > > (regexp-opt (append (mapcar (lambda (kw) > (concat "m4_" kw)) > prefixed) > prefixed > unprefixed)) > > with prefixed containing: > > '("builtin" "changecom" "changequote" "changeword" "debugfile" > "debugmode" "decr" "define" "defn" "divert" "divnum" "dnl" > "dumpdef" "errprint" "esyscmd" "eval" "file" "format" > "ifdef" "ifelse" "include" "incr" "index" "indir" "len" "line" > "m4exit" "m4wrap" "maketemp" "patsubst" "popdef" "pushdef" "regexp" > "shift" "sinclude" "substr" "syscmd" "sysval" "traceoff" "traceon" > "translit" "undefine" "undivert" "unix")) > > > and unprefixed containing: > > '("gnu") > > > Or maybe the absence of m4_gnu is a typo, in which case the logic could > be slightly simpler. I'm assuming that "m4_m4_undefine" at the bottom of > the file is a mistake. > > Sorry there's no patch: I've requested assignment papers, but they > haven't come through yet. Since I think I've hit my minimal change > limit, someone else gets to type the code... [...] Content analysis details: (1.8 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [195.110.48.8 listed in list.dnswl.org] 2.5 DRUGS_MUSCLE Refers to a muscle relaxant On 2015-02-16, at 11:32, Rupert Swarbrick wrote: > In m4-mode.el, the last two sexps in m4-font-lock-keywords are the wrong > way around. As a result, if you are writing M4 code to be expanded in > "-P mode", so have things like > > m4_define > > in the file, then the "define" part gets matched by the penultimate > regex, so m4_ doesn't get highlighted as part of a keyword. > > I think the fix for this is to just swap the two regexes around. That > said, the commented stuff at the bottom of the file is rather > ugly. Maybe it would be better to have a single regex, made with > something like: > > (regexp-opt (append (mapcar (lambda (kw) > (concat "m4_" kw)) > prefixed) > prefixed > unprefixed)) > > with prefixed containing: > > '("builtin" "changecom" "changequote" "changeword" "debugfile" > "debugmode" "decr" "define" "defn" "divert" "divnum" "dnl" > "dumpdef" "errprint" "esyscmd" "eval" "file" "format" > "ifdef" "ifelse" "include" "incr" "index" "indir" "len" "line" > "m4exit" "m4wrap" "maketemp" "patsubst" "popdef" "pushdef" "regexp" > "shift" "sinclude" "substr" "syscmd" "sysval" "traceoff" "traceon" > "translit" "undefine" "undivert" "unix")) > > > and unprefixed containing: > > '("gnu") > > > Or maybe the absence of m4_gnu is a typo, in which case the logic could > be slightly simpler. I'm assuming that "m4_m4_undefine" at the bottom of > the file is a mistake. > > Sorry there's no patch: I've requested assignment papers, but they > haven't come through yet. Since I think I've hit my minimal change > limit, someone else gets to type the code... Hi, in case the problem is still there (I don't use m4, so it's difficult for me to verify it), would you be able to provide a patch now? > Rupert Best, -- Marcin From debbugs-submit-bounces@debbugs.gnu.org Tue Jun 05 20:09:24 2018 Received: (at 19882) by debbugs.gnu.org; 6 Jun 2018 00:09:24 +0000 Received: from localhost ([127.0.0.1]:35646 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fQM0y-0007lc-Ko for submit@debbugs.gnu.org; Tue, 05 Jun 2018 20:09:24 -0400 Received: from mail-io0-f196.google.com ([209.85.223.196]:34112) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fQM0t-0007lG-Ij; Tue, 05 Jun 2018 20:09:20 -0400 Received: by mail-io0-f196.google.com with SMTP id e15-v6so5583336iog.1; Tue, 05 Jun 2018 17:09:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=HCDCKQx5My2yIuGZV3X/YOPwmPIOfCEHODesFN5z9pM=; b=N2T7PpJxCAnSXF3UpHt+sqc66ylC5KJfl0isoZKMOnPeZUH5UQaQrcVxHntzhb0mhq jJovf2ivygHhdBVI/bHnaPW+5qtEJG9dhXcD9QAOuCKYiWSNVvkujQh4J79EJGZeMIoj bAfxwmyv0HNLabSibgMKJQ2rcgdSKBY4Dg5h0UmDllanYuQwau31LgfmlKy54f+V70pg pXX+0Os0IBM/uOAoveEdsBKBTtT+HznfPFPiQ4bHwsZDxH0z+xHs4IKppsXzwAd38eAM itxmBDY5hfG7+YIIdQQFO1tetal74MqIZ0Jgn+0zdc6KNt526fxX34XH3Z9f8W/8+CFy /chg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=HCDCKQx5My2yIuGZV3X/YOPwmPIOfCEHODesFN5z9pM=; b=QGCJztHwAmj+7VZjbhBWC0rPurzLzLA0a377rv3OAYJcuMe9yxp+uv94JIUmdFJOuo uUyzUFAA5/kFHpEeOHDOcRNBJl489wAqOtFK/DEZWTMxIIcybiB/kNN3oJR/rGH5n1cg qGJ1dXwtEAb/eYV9zNgCkwUVMdqXDRe3t5bo1UIGyzpsMqGRYPaZnrP+PrQCRmtHnfZb L8zYtWco7QK+xoOjnroCMMxhfXt983lG5zP3BTUibYrHmzjLYwF332epG93qUjdJymMh nxH/kJyLmWx4UxhhWnQcR++NB7mTnrkJlFL2BJxtKNVK/dpsLPS0mOW8y9slQHpKF76E lTbQ== X-Gm-Message-State: APt69E2iVfi+Snb0ZIKu5Oe+nrG3riyw21Q8cXHn+dz1XyMl663eP5vE QccIKe+BYgKd+AC5PARQHFzpJ3id X-Google-Smtp-Source: ADUXVKImACLce649KEYLUGxnCWZBySbD7tCGeOhwEQt+EDonJ/yf3ggZ4aktHjlLQQgE/5r12b/VMg== X-Received: by 2002:a6b:b0c3:: with SMTP id z186-v6mr781141ioe.220.1528243754087; Tue, 05 Jun 2018 17:09:14 -0700 (PDT) Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.googlemail.com with ESMTPSA id a43-v6sm1296502itj.11.2018.06.05.17.09.13 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 05 Jun 2018 17:09:13 -0700 (PDT) From: Noam Postavsky To: Marcin Borkowski Subject: Re: bug#19882: 25.0.50; Backwards font-lock regex in m4-mode References: <889iof2rt04.fsf@broadcom.com> <87bn68e6tv.fsf@mbork.pl> Date: Tue, 05 Jun 2018 20:09:12 -0400 In-Reply-To: <87bn68e6tv.fsf@mbork.pl> (Marcin Borkowski's message of "Mon, 21 Mar 2016 06:30:20 +0100") Message-ID: <87po146ajb.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 1.7 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: tags 19882 fixed close 19882 25.1 quit Marcin Borkowski writes: > On 2015-02-16, at 11:32, Rupert Swarbrick wrote: > >> In m4-mode.el, the last two sexps in m4-font-lock-keywords are the wrong >> way around. As a result, if you are writing M4 code to be expanded in >> "-P mode", so have things like >> >> m4_define >> >> in the file, then the "define" part gets matched by the penultimate >> regex, so m4_ doesn't get highlighted as part of a keyword. [...] Content analysis details: (1.7 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [209.85.223.196 listed in list.dnswl.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (npostavs[at]gmail.com) -0.8 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.223.196 listed in wl.mailspike.net] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 T_DKIM_INVALID DKIM-Signature header exists but is not valid 2.5 DRUGS_MUSCLE Refers to a muscle relaxant X-Debbugs-Envelope-To: 19882 Cc: Rupert Swarbrick , 19882@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.7 (/) tags 19882 fixed close 19882 25.1 quit Marcin Borkowski writes: > On 2015-02-16, at 11:32, Rupert Swarbrick wrote: > >> In m4-mode.el, the last two sexps in m4-font-lock-keywords are the wrong >> way around. As a result, if you are writing M4 code to be expanded in >> "-P mode", so have things like >> >> m4_define >> >> in the file, then the "define" part gets matched by the penultimate >> regex, so m4_ doesn't get highlighted as part of a keyword. > in case the problem is still there (I don't use m4, so it's difficult > for me to verify it), would you be able to provide a patch now? Seems to be fixed in 25 (I did M-x m4-mode and typed in m4_define). From unknown Fri Sep 05 15:37:04 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Wed, 04 Jul 2018 11:24:06 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator