From unknown Sat Jun 21 10:39:39 2025 X-Loop: help-debbugs@gnu.org Subject: bug#15941: 24.2; Shell-script mode's syntax highligting gets confused by shift (<<) operator like in '$((1 << 32)) Resent-From: Ilya Tatar Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 20 Nov 2013 22:15:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 15941 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 15941@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.138498564921170 (code B ref -1); Wed, 20 Nov 2013 22:15:02 +0000 Received: (at submit) by debbugs.gnu.org; 20 Nov 2013 22:14:09 +0000 Received: from localhost ([127.0.0.1]:35299 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VjG2C-0005VN-DG for submit@debbugs.gnu.org; Wed, 20 Nov 2013 17:14:09 -0500 Received: from eggs.gnu.org ([208.118.235.92]:37909) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VjFqS-0005CG-FI for submit@debbugs.gnu.org; Wed, 20 Nov 2013 17:02:01 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VjFqH-00063X-Px for submit@debbugs.gnu.org; Wed, 20 Nov 2013 17:01:55 -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.0 required=5.0 tests=BAYES_40,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:35138) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VjFqH-00063T-NG for submit@debbugs.gnu.org; Wed, 20 Nov 2013 17:01:49 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:39629) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VjFqC-00006w-UF for bug-gnu-emacs@gnu.org; Wed, 20 Nov 2013 17:01:49 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VjFq8-0005zk-7n for bug-gnu-emacs@gnu.org; Wed, 20 Nov 2013 17:01:44 -0500 Received: from usindpps05.hds.com ([207.126.252.18]:33744) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VjFq7-0005si-Vg for bug-gnu-emacs@gnu.org; Wed, 20 Nov 2013 17:01:40 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=hds.com; h=message-id : date : from : mime-version : to : subject : content-type : content-transfer-encoding; s=mail1; bh=GEbZWLohkIxrhXkHEdWdWeAuv8kGMgBLyASExUElP6s=; b=cQgwJVRhU/W5MI0NNozYtsHuq0VJJI5WbelFo2GMTxVwguoQvVpUFCwO6bSsM48dQQYx Vlh8I60iQf3+COQJ9VNPwznoM+JVChMoAF3NusCKTHvfPCSSw8x1MvURJhiwGA+nZS0/ l1KmLkU56H/G3WSx5lW/IWr2YbqfiRtmljh1Ft/EnK/xrPClFYADLxbYQoBZ+GPzu8jc sZzJO9mdgmJWGU8aSbA13q2/O/Mnrv+hT41X+mS8ea5P2FH3bejRVNrlRu/PFuqe1Xeo clfxBVGg1ZCnC/6/V0wPMSv85+y+8yb6ZmiWC4wDVLTLQxm+ynw5kp20sMJo5LIFKMWH +g== Received: from usindmail01.hds.com (usindmail03 [207.126.252.22]) by usindpps05.hds.com (8.14.5/8.14.5) with ESMTP id rAKM1Vmk008508 for ; Wed, 20 Nov 2013 17:01:31 -0500 Received: from itatar-dt.archivas.com (usindnetf5d-vlan47float.corp.hds.com [10.74.73.11]) by usindmail01.hds.com (8.14.1/8.14.1) with ESMTP id rAKM11DC003575 for ; Wed, 20 Nov 2013 17:01:03 -0500 (EST) Message-ID: <528D3139.8060400@hds.com> Date: Wed, 20 Nov 2013 17:01:29 -0500 From: Ilya Tatar User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130805 Thunderbird/17.0.8 MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Proofpoint-SPF-Result: pass X-Proofpoint-SPF-Record: v=spf1 mx ip4:207.126.244.0/26 ip4:207.126.252.0/25 include:mktomail.com include:cloud.hds.com ~all X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.10.8794, 1.0.14, 0.0.0000 definitions=2013-11-20_07:2013-11-20,2013-11-20,1970-01-01 signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=outbound_policy score=0 spamscore=0 suspectscore=4 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=7.0.1-1305240000 definitions=main-1311200168 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x 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: -4.0 (----) X-Mailman-Approved-At: Wed, 20 Nov 2013 17:14:07 -0500 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: -4.0 (----) This bug report will be sent to the Bug-GNU-Emacs mailing list and the GNU bug tracker at debbugs.gnu.org. Please check that the From: line contains a valid email address. After a delay of up to one day, you should receive an acknowledgement at that address. Please write in English if possible, as the Emacs maintainers usually do not have translators for other languages. Please describe exactly what actions triggered the bug, and the precise symptoms of the bug. If you can, give a recipe starting from `emacs -Q': 1. create a file that starts with '#! /bin/bash'. This will use Shell-script mode 2. add this line to it echo $((1 << 32)) everything that follows this line will be highlighted as though it is a comment If Emacs crashed, and you have the Emacs process in the gdb debugger, please include the output from the following gdb commands: `bt full' and `xbacktrace'. For information about debugging Emacs, please read the file /usr/share/emacs/24.2/etc/DEBUG. In GNU Emacs 24.2.1 (x86_64-redhat-linux-gnu, GTK+ Version 3.6.4) of 2013-07-14 on buildvm-05.phx2.fedoraproject.org Windowing system distributor `Fedora Project', version 11.0.11303000 Configured using: `configure '--build=x86_64-redhat-linux-gnu' '--host=x86_64-redhat-linux-gnu' '--program-prefix=' '--disable-dependency-tracking' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib64' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/var/lib' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--with-dbus' '--with-gif' '--with-jpeg' '--with-png' '--with-rsvg' '--with-tiff' '--with-xft' '--with-xpm' '--with-x-toolkit=gtk3' '--with-gpm=no' '--with-wide-int' 'build_alias=x86_64-redhat-linux-gnu' 'host_alias=x86_64-redhat-linux-gnu' 'CFLAGS=-DMAIL_USE_LOCKF -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic' 'LDFLAGS=-Wl,-z,relro '' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: en_US.UTF-8 value of $XMODIFIERS: @im=none locale-coding-system: utf-8-unix default enable-multibyte-characters: t Major mode: Shell-script Minor modes in effect: global-auto-complete-mode: t auto-complete-mode: t tooltip-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Recent input: C-x C-f t m b i n / t m s M-x e m a v e r C-g s h e l l - s c r C-g C-g C-x v M C-x m C-x k C-h m C-x o C-s s h e l C-a C-x o Recent messages: For information about GNU Emacs and the GNU system, type C-h C-a. Setting up indent for shell type bash setting up indent stuff Indentation variables are now local. Indentation setup for shell type bash GNU Emacs 24.2.1 (x86_64-redhat-linux-gnu, GTK+ Version 3.6.4) of 2013-07-14 on buildvm-05.phx2.fedoraproject.org Quit [3 times] vc-deduce-fileset: No fileset is available here Type C-x 1 to delete the help window, C-M-v to scroll help. Mark saved where search started Load-path shadows: From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 20 17:15:48 2013 Received: (at control) by debbugs.gnu.org; 20 Nov 2013 22:15:48 +0000 Received: from localhost ([127.0.0.1]:35304 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VjG3n-0005Yj-Hj for submit@debbugs.gnu.org; Wed, 20 Nov 2013 17:15:47 -0500 Received: from fencepost.gnu.org ([208.118.235.10]:49847 ident=Debian-exim) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VjG3m-0005Yb-3C for control@debbugs.gnu.org; Wed, 20 Nov 2013 17:15:46 -0500 Received: from rgm by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1VjG3l-0008Rn-MA for control@debbugs.gnu.org; Wed, 20 Nov 2013 17:15:45 -0500 Date: Wed, 20 Nov 2013 17:15:45 -0500 Message-Id: Subject: control message for bug 15941 To: X-Mailer: mail (GNU Mailutils 2.1) From: Glenn Morris X-Spam-Score: -5.5 (-----) X-Debbugs-Envelope-To: control 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: -5.5 (-----) merge 8632 15941 From unknown Sat Jun 21 10:39:39 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.503 (Entity 5.503) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Ilya Tatar Subject: bug#15941: closed (Re: bug#15941: 24.2; Shell-script mode's syntax highligting gets confused by shift (<<) operator like in '$((1 << 32))) Message-ID: References: <528D3139.8060400@hds.com> X-Gnu-PR-Message: they-closed 15941 X-Gnu-PR-Package: emacs Reply-To: 15941@debbugs.gnu.org Date: Thu, 21 Nov 2013 01:42:03 +0000 Content-Type: multipart/mixed; boundary="----------=_1384998123-13270-1" This is a multi-part message in MIME format... ------------=_1384998123-13270-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #15941: 24.2; Shell-script mode's syntax highligting gets confused by shift= (<<) operator like in '$((1 << 32)) 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 15941@debbugs.gnu.org. --=20 15941: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D15941 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1384998123-13270-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 15941-done) by debbugs.gnu.org; 21 Nov 2013 01:41:12 +0000 Received: from localhost ([127.0.0.1]:35509 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VjJGZ-0003Qz-LL for submit@debbugs.gnu.org; Wed, 20 Nov 2013 20:41:12 -0500 Received: from ironport2-out.teksavvy.com ([206.248.154.181]:6931) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VjJGV-0003Qi-N8 for 15941-done@debbugs.gnu.org; Wed, 20 Nov 2013 20:41:08 -0500 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av4EABK/CFHO+KWN/2dsb2JhbABEvw4Xc4IfAQVWIwULCzQHCxQYDSSIJMEtkQoDiGGcGYFegxU X-IPAS-Result: Av4EABK/CFHO+KWN/2dsb2JhbABEvw4Xc4IfAQVWIwULCzQHCxQYDSSIJMEtkQoDiGGcGYFegxU X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="38806994" Received: from 206-248-165-141.dsl.teksavvy.com (HELO pastel.home) ([206.248.165.141]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 20 Nov 2013 20:41:01 -0500 Received: by pastel.home (Postfix, from userid 20848) id 6A99E60789; Wed, 20 Nov 2013 20:41:00 -0500 (EST) From: Stefan Monnier To: Ilya Tatar Subject: Re: bug#15941: 24.2; Shell-script mode's syntax highligting gets confused by shift (<<) operator like in '$((1 << 32)) Message-ID: References: <528D3139.8060400@hds.com> Date: Wed, 20 Nov 2013 20:41:00 -0500 In-Reply-To: <528D3139.8060400@hds.com> (Ilya Tatar's message of "Wed, 20 Nov 2013 17:01:29 -0500") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 15941-done Cc: 15941-done@debbugs.gnu.org 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: 0.3 (/) > 2. add this line to it > echo $((1 << 32)) > everything that follows this line will be highlighted as though it > is a comment [...] > In GNU Emacs 24.2.1 (x86_64-redhat-linux-gnu, GTK+ Version 3.6.4) Thank you. This is already fixed in 24.3. Stefan ------------=_1384998123-13270-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 20 Nov 2013 22:14:09 +0000 Received: from localhost ([127.0.0.1]:35299 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VjG2C-0005VN-DG for submit@debbugs.gnu.org; Wed, 20 Nov 2013 17:14:09 -0500 Received: from eggs.gnu.org ([208.118.235.92]:37909) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VjFqS-0005CG-FI for submit@debbugs.gnu.org; Wed, 20 Nov 2013 17:02:01 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VjFqH-00063X-Px for submit@debbugs.gnu.org; Wed, 20 Nov 2013 17:01:55 -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.0 required=5.0 tests=BAYES_40,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:35138) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VjFqH-00063T-NG for submit@debbugs.gnu.org; Wed, 20 Nov 2013 17:01:49 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:39629) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VjFqC-00006w-UF for bug-gnu-emacs@gnu.org; Wed, 20 Nov 2013 17:01:49 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VjFq8-0005zk-7n for bug-gnu-emacs@gnu.org; Wed, 20 Nov 2013 17:01:44 -0500 Received: from usindpps05.hds.com ([207.126.252.18]:33744) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VjFq7-0005si-Vg for bug-gnu-emacs@gnu.org; Wed, 20 Nov 2013 17:01:40 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=hds.com; h=message-id : date : from : mime-version : to : subject : content-type : content-transfer-encoding; s=mail1; bh=GEbZWLohkIxrhXkHEdWdWeAuv8kGMgBLyASExUElP6s=; b=cQgwJVRhU/W5MI0NNozYtsHuq0VJJI5WbelFo2GMTxVwguoQvVpUFCwO6bSsM48dQQYx Vlh8I60iQf3+COQJ9VNPwznoM+JVChMoAF3NusCKTHvfPCSSw8x1MvURJhiwGA+nZS0/ l1KmLkU56H/G3WSx5lW/IWr2YbqfiRtmljh1Ft/EnK/xrPClFYADLxbYQoBZ+GPzu8jc sZzJO9mdgmJWGU8aSbA13q2/O/Mnrv+hT41X+mS8ea5P2FH3bejRVNrlRu/PFuqe1Xeo clfxBVGg1ZCnC/6/V0wPMSv85+y+8yb6ZmiWC4wDVLTLQxm+ynw5kp20sMJo5LIFKMWH +g== Received: from usindmail01.hds.com (usindmail03 [207.126.252.22]) by usindpps05.hds.com (8.14.5/8.14.5) with ESMTP id rAKM1Vmk008508 for ; Wed, 20 Nov 2013 17:01:31 -0500 Received: from itatar-dt.archivas.com (usindnetf5d-vlan47float.corp.hds.com [10.74.73.11]) by usindmail01.hds.com (8.14.1/8.14.1) with ESMTP id rAKM11DC003575 for ; Wed, 20 Nov 2013 17:01:03 -0500 (EST) Message-ID: <528D3139.8060400@hds.com> Date: Wed, 20 Nov 2013 17:01:29 -0500 From: Ilya Tatar User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130805 Thunderbird/17.0.8 MIME-Version: 1.0 To: bug-gnu-emacs@gnu.org Subject: 24.2; Shell-script mode's syntax highligting gets confused by shift (<<) operator like in '$((1 << 32)) Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Proofpoint-SPF-Result: pass X-Proofpoint-SPF-Record: v=spf1 mx ip4:207.126.244.0/26 ip4:207.126.252.0/25 include:mktomail.com include:cloud.hds.com ~all X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.10.8794, 1.0.14, 0.0.0000 definitions=2013-11-20_07:2013-11-20,2013-11-20,1970-01-01 signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=outbound_policy score=0 spamscore=0 suspectscore=4 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=7.0.1-1305240000 definitions=main-1311200168 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x 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: -4.0 (----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Wed, 20 Nov 2013 17:14:07 -0500 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: -4.0 (----) This bug report will be sent to the Bug-GNU-Emacs mailing list and the GNU bug tracker at debbugs.gnu.org. Please check that the From: line contains a valid email address. After a delay of up to one day, you should receive an acknowledgement at that address. Please write in English if possible, as the Emacs maintainers usually do not have translators for other languages. Please describe exactly what actions triggered the bug, and the precise symptoms of the bug. If you can, give a recipe starting from `emacs -Q': 1. create a file that starts with '#! /bin/bash'. This will use Shell-script mode 2. add this line to it echo $((1 << 32)) everything that follows this line will be highlighted as though it is a comment If Emacs crashed, and you have the Emacs process in the gdb debugger, please include the output from the following gdb commands: `bt full' and `xbacktrace'. For information about debugging Emacs, please read the file /usr/share/emacs/24.2/etc/DEBUG. In GNU Emacs 24.2.1 (x86_64-redhat-linux-gnu, GTK+ Version 3.6.4) of 2013-07-14 on buildvm-05.phx2.fedoraproject.org Windowing system distributor `Fedora Project', version 11.0.11303000 Configured using: `configure '--build=x86_64-redhat-linux-gnu' '--host=x86_64-redhat-linux-gnu' '--program-prefix=' '--disable-dependency-tracking' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib64' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/var/lib' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--with-dbus' '--with-gif' '--with-jpeg' '--with-png' '--with-rsvg' '--with-tiff' '--with-xft' '--with-xpm' '--with-x-toolkit=gtk3' '--with-gpm=no' '--with-wide-int' 'build_alias=x86_64-redhat-linux-gnu' 'host_alias=x86_64-redhat-linux-gnu' 'CFLAGS=-DMAIL_USE_LOCKF -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic' 'LDFLAGS=-Wl,-z,relro '' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: en_US.UTF-8 value of $XMODIFIERS: @im=none locale-coding-system: utf-8-unix default enable-multibyte-characters: t Major mode: Shell-script Minor modes in effect: global-auto-complete-mode: t auto-complete-mode: t tooltip-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Recent input: C-x C-f t m b i n / t m s M-x e m a v e r C-g s h e l l - s c r C-g C-g C-x v M C-x m C-x k C-h m C-x o C-s s h e l C-a C-x o Recent messages: For information about GNU Emacs and the GNU system, type C-h C-a. Setting up indent for shell type bash setting up indent stuff Indentation variables are now local. Indentation setup for shell type bash GNU Emacs 24.2.1 (x86_64-redhat-linux-gnu, GTK+ Version 3.6.4) of 2013-07-14 on buildvm-05.phx2.fedoraproject.org Quit [3 times] vc-deduce-fileset: No fileset is available here Type C-x 1 to delete the help window, C-M-v to scroll help. Mark saved where search started Load-path shadows: ------------=_1384998123-13270-1-- From unknown Sat Jun 21 10:39:39 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.503 (Entity 5.503) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Ben Wong Subject: bug#8632: closed (Re: bug#15941: 24.2; Shell-script mode's syntax highligting gets confused by shift (<<) operator like in '$((1 << 32))) Message-ID: References: <7jmxiz1mlu.fsf@asome.wongs.net> X-Gnu-PR-Message: they-closed 8632 X-Gnu-PR-Package: emacs Reply-To: 8632@debbugs.gnu.org Date: Thu, 21 Nov 2013 01:42:04 +0000 Content-Type: multipart/mixed; boundary="----------=_1384998124-13270-3" This is a multi-part message in MIME format... ------------=_1384998124-13270-3 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #15941: 23.2; shell-script[bash] doesn't handle bitshift $(( 1 << 16 )) 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 8632@debbugs.gnu.org. --=20 15941: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D15941 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1384998124-13270-3 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 15941-done) by debbugs.gnu.org; 21 Nov 2013 01:41:12 +0000 Received: from localhost ([127.0.0.1]:35509 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VjJGZ-0003Qz-LL for submit@debbugs.gnu.org; Wed, 20 Nov 2013 20:41:12 -0500 Received: from ironport2-out.teksavvy.com ([206.248.154.181]:6931) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VjJGV-0003Qi-N8 for 15941-done@debbugs.gnu.org; Wed, 20 Nov 2013 20:41:08 -0500 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av4EABK/CFHO+KWN/2dsb2JhbABEvw4Xc4IfAQVWIwULCzQHCxQYDSSIJMEtkQoDiGGcGYFegxU X-IPAS-Result: Av4EABK/CFHO+KWN/2dsb2JhbABEvw4Xc4IfAQVWIwULCzQHCxQYDSSIJMEtkQoDiGGcGYFegxU X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="38806994" Received: from 206-248-165-141.dsl.teksavvy.com (HELO pastel.home) ([206.248.165.141]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 20 Nov 2013 20:41:01 -0500 Received: by pastel.home (Postfix, from userid 20848) id 6A99E60789; Wed, 20 Nov 2013 20:41:00 -0500 (EST) From: Stefan Monnier To: Ilya Tatar Subject: Re: bug#15941: 24.2; Shell-script mode's syntax highligting gets confused by shift (<<) operator like in '$((1 << 32)) Message-ID: References: <528D3139.8060400@hds.com> Date: Wed, 20 Nov 2013 20:41:00 -0500 In-Reply-To: <528D3139.8060400@hds.com> (Ilya Tatar's message of "Wed, 20 Nov 2013 17:01:29 -0500") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 15941-done Cc: 15941-done@debbugs.gnu.org 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: 0.3 (/) > 2. add this line to it > echo $((1 << 32)) > everything that follows this line will be highlighted as though it > is a comment [...] > In GNU Emacs 24.2.1 (x86_64-redhat-linux-gnu, GTK+ Version 3.6.4) Thank you. This is already fixed in 24.3. Stefan ------------=_1384998124-13270-3 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 6 May 2011 23:34:03 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QIUX4-0000on-Ea for submit@debbugs.gnu.org; Fri, 06 May 2011 19:34:03 -0400 Received: from eggs.gnu.org ([140.186.70.92]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QIUPz-0000eT-3w for submit@debbugs.gnu.org; Fri, 06 May 2011 19:26:43 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QIUPt-00054S-3K for submit@debbugs.gnu.org; Fri, 06 May 2011 19:26:37 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on eggs.gnu.org X-Spam-Level: ** X-Spam-Status: No, score=2.4 required=5.0 tests=BAYES_00,RCVD_IN_PBL, RCVD_IN_SORBS_DUL,RDNS_DYNAMIC autolearn=no version=3.3.1 Received: from lists.gnu.org ([140.186.70.17]:40278) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QIUPt-00054O-1f for submit@debbugs.gnu.org; Fri, 06 May 2011 19:26:37 -0400 Received: from eggs.gnu.org ([140.186.70.92]:53355) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QIUPs-0006vu-5Z for bug-gnu-emacs@gnu.org; Fri, 06 May 2011 19:26:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QIUPr-000545-66 for bug-gnu-emacs@gnu.org; Fri, 06 May 2011 19:26:36 -0400 Received: from c-67-183-110-101.hsd1.wa.comcast.net ([67.183.110.101]:46875 helo=asome.wongs.net) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QIUPr-000541-0T for bug-gnu-emacs@gnu.org; Fri, 06 May 2011 19:26:35 -0400 Received: from ben by asome.wongs.net with local (Exim 4.75) (envelope-from ) id 1QITev-0001oG-M8 for bug-gnu-emacs@gnu.org; Fri, 06 May 2011 15:38:05 -0700 From: Ben Wong To: bug-gnu-emacs@gnu.org Subject: 23.2; shell-script[bash] doesn't handle bitshift $(( 1 << 16 )) Date: Fri, 06 May 2011 15:38:05 -0700 Message-ID: <7jmxiz1mlu.fsf@asome.wongs.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 140.186.70.17 X-Spam-Score: -6.0 (------) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Fri, 06 May 2011 19:34:01 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.0 (------) In shell-script mode (bash minor mode) Emacs 23.2 incorrectly parses the following line as a HERE DOCUMENT. echo $(( 1 << 16 )) It is confused because sh-font-lock-open-heredoc (in sh-script.el) does not know about bash's ARITHMETIC EXPANSION. There should be a function, similar to sh-in-comment-or-string, which parses the script looking for arithmetic expansion. As a temporary workaround for users, I believe it is legal to put double quotes around any arithmetic expansion to force emacs to view it as a string. In GNU Emacs 23.2.1 (i486-pc-linux-gnu, GTK+ Version 2.20.0) of 2010-12-11 on raven, modified by Debian configured using `configure '--build' 'i486-linux-gnu' '--build' 'i486-linux-gnu' '--prefix=/usr' '--sharedstatedir=/var/lib' '--libexecdir=/usr/lib' '--localstatedir=/var/lib' '--infodir=/usr/share/info' '--mandir=/usr/share/man' '--with-pop=yes' '--enable-locallisppath=/etc/emacs23:/etc/emacs:/usr/local/share/emacs/23.2/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/23.2/site-lisp:/usr/share/emacs/site-lisp:/usr/share/emacs/23.2/leim' '--with-x=yes' '--with-x-toolkit=gtk' '--with-toolkit-scroll-bars' 'build_alias=i486-linux-gnu' 'CFLAGS=-DDEBIAN -g -O2' 'LDFLAGS=-g' 'CPPFLAGS='' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: en_US.UTF-8 value of $XMODIFIERS: nil locale-coding-system: utf-8-unix default enable-multibyte-characters: t Major mode: Shell-script Minor modes in effect: shell-dirtrack-mode: t gpm-mouse-mode: t which-function-mode: t show-paren-mode: t display-time-mode: t recentf-mode: t iswitchb-mode: t tooltip-mode: t mouse-wheel-mode: t tool-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t auto-encryption-mode: t auto-compression-mode: t size-indication-mode: t line-number-mode: t ------------=_1384998124-13270-3--