GNU bug report logs - #34301
Unable to make underscore part of a word everywhere

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Reported by: Konstantin Kharlamov <hi-angel@HIDDEN>; dated Sun, 3 Feb 2019 18:11:02 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.

Message received at 34301 <at> debbugs.gnu.org:


Received: (at 34301) by debbugs.gnu.org; 9 Jul 2019 18:07:52 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Jul 09 14:07:52 2019
Received: from localhost ([127.0.0.1]:34137 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hkuWu-0004ZU-8N
	for submit <at> debbugs.gnu.org; Tue, 09 Jul 2019 14:07:52 -0400
Received: from mail-io1-f52.google.com ([209.85.166.52]:37023)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <npostavs@HIDDEN>) id 1hkuWs-0004ZG-1P
 for 34301 <at> debbugs.gnu.org; Tue, 09 Jul 2019 14:07:50 -0400
Received: by mail-io1-f52.google.com with SMTP id q22so23328432iog.4
 for <34301 <at> debbugs.gnu.org>; Tue, 09 Jul 2019 11:07:50 -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=N4R6KHUyGF7RInilL2DROFOqTI/Fmtd0rcAzJScNzrc=;
 b=kEJWNAXb6+wOdpq2wXamsA9dorh7MukXrV+11Di/ycMDum3crwxqf8Jbm45CMkdROi
 FGGVPn5QsLtEqteIi2u29AbFQNDxhmPoeow2lrIk3pEs5Y//DAJdFQWeLZmLjkKO2g5B
 /n99XLGhg6WXDUjqyGo7Inyeehy9uDm4v5zDjAkpd9CF91tSolbOJIxS864lbDpO05sA
 R7tgqtQncS4R33MZDL6RTe0ZS/0DcvZvgVYMm27LwoQS8I6RKDlBTh4n2UAvsCM9k148
 GItR0rzYnzaLecYD4fCw5OvfB4+o8sdeIMjsk7uaBM4qPdwEvbwhtsxHtifDu3QPvcmC
 RsUQ==
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=N4R6KHUyGF7RInilL2DROFOqTI/Fmtd0rcAzJScNzrc=;
 b=Q/SB1zIjpDJ14vR3CuzTyKAuCHbG45okWxKxIP2lgcwwX2Up5DlHSBJ3wzS61earO0
 gxkZr14YFbm3rFML+48LIAVB45mkDfmbIojhHKyf40/qLl4X4oaUrD7hQIywNJwXMOYG
 u7V8rnwUWm8Fk50lM8uQrL7q961rNWYJhJa0QmilYn2ySKBXHSBGk3O5zBkQX6vkWCqK
 73xx43PSRrikendeF46eva03oohVlb5B+mUVEXBUYYB9Ex7MTjnlVPmktI88WB2ZBGHl
 mn8cgVgyijF3WTJARqsO76wy9IF65j25DeZpYr+E6q1cBwDQxKsT2rPwHf1etBXhgpD4
 AOEg==
X-Gm-Message-State: APjAAAUaMxBmfmZMfXAV9rSwD5yP2CNpPCiFRpEEgL9hU6OZqFk6E9O0
 295NmhU18GZ9yXOYbBAkN7H9qpkJ
X-Google-Smtp-Source: APXvYqyTRiQolp+L0Lz8gBIkS6PN5HBjBzhq2ymit9CYmQBov1Y0loRHdUIOMtedCineImsEBAV7Sg==
X-Received: by 2002:a02:1441:: with SMTP id 62mr30948377jag.21.1562695664136; 
 Tue, 09 Jul 2019 11:07:44 -0700 (PDT)
Received: from vhost2
 (CPE001143542e1f-CMf81d0f809fa0.cpe.net.cable.rogers.com. [99.230.51.196])
 by smtp.gmail.com with ESMTPSA id h18sm16951409iob.80.2019.07.09.11.07.43
 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
 Tue, 09 Jul 2019 11:07:43 -0700 (PDT)
From: Noam Postavsky <npostavs@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
Subject: Re: bug#34301: Unable to make underscore part of a word everywhere
References: <ca54ab04-9d70-cdc0-d09f-6609e9d43971@HIDDEN>
 <874l3vrv0s.fsf@HIDDEN>
Date: Tue, 09 Jul 2019 14:07:44 -0400
In-Reply-To: <874l3vrv0s.fsf@HIDDEN> (Lars Ingebrigtsen's message of
 "Tue, 09 Jul 2019 19:13:23 +0200")
Message-ID: <85zhlncc9b.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1.92 (windows-nt)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: 1.3 (+)
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:  Lars Ingebrigtsen writes: > Konstantin Kharlamov writes: >
 >> By default the underscore "_" symbol is not being counted as part of a
 >> word, even though I have never met a language where it's a separate >>
 entity. > > In na [...] 
 Content analysis details:   (1.3 points, 10.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 0.0 URIBL_BLOCKED          ADMINISTRATOR NOTICE: The query to URIBL was
 blocked.  See
 http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block
 for more information. [URIs: yandex.ru]
 -0.0 SPF_PASS               SPF: sender matches SPF record
 0.0 FREEMAIL_FROM          Sender email is commonly abused enduser mail
 provider (npostavs[at]gmail.com)
 0.0 SPF_HELO_NONE          SPF: HELO does not publish an SPF Record
 -0.0 RCVD_IN_DNSWL_NONE     RBL: Sender listed at https://www.dnswl.org/,
 no trust [209.85.166.52 listed in list.dnswl.org]
 1.3 PDS_NO_HELO_DNS        High profile HELO but no A record
X-Debbugs-Envelope-To: 34301
Cc: 34301 <at> debbugs.gnu.org, Konstantin Kharlamov <hi-angel@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: 0.3 (/)

Lars Ingebrigtsen <larsi@HIDDEN> writes:

> Konstantin Kharlamov <hi-angel@HIDDEN> writes:
>
>> By default the underscore "_" symbol is not being counted as part of a
>> word, even though I have never met a language where it's a separate
>> entity.
>
> In natural languages it's usually not word-consistent.
>
>> This means e.g. that upon opening a file one is never being
>> able to "search for word_wth_underscores under cursor", unless they
>> modify current table.
>
> Any programming language mode sets _ to be part of words, surely?  If
> not that's a bug in that mode?  What modes do you see this in?

Most languages give '_' symbol, not word, syntax.  Looking at the linked
SE thread, this sounds more like a problem with evil though, apparently
it's difficult to search for a symbol?





Information forwarded to bug-gnu-emacs@HIDDEN:
bug#34301; Package emacs. Full text available.

Message received at 34301 <at> debbugs.gnu.org:


Received: (at 34301) by debbugs.gnu.org; 9 Jul 2019 17:13:30 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Jul 09 13:13:30 2019
Received: from localhost ([127.0.0.1]:34088 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hktgH-0005FX-RK
	for submit <at> debbugs.gnu.org; Tue, 09 Jul 2019 13:13:30 -0400
Received: from quimby.gnus.org ([80.91.231.51]:50000)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1hktgG-0005FM-5D
 for 34301 <at> debbugs.gnu.org; Tue, 09 Jul 2019 13:13:29 -0400
Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=marnie)
 by quimby.gnus.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.89) (envelope-from <larsi@HIDDEN>)
 id 1hktgC-0007Un-2t; Tue, 09 Jul 2019 19:13:26 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Konstantin Kharlamov <hi-angel@HIDDEN>
Subject: Re: bug#34301: Unable to make underscore part of a word everywhere
References: <ca54ab04-9d70-cdc0-d09f-6609e9d43971@HIDDEN>
Date: Tue, 09 Jul 2019 19:13:23 +0200
In-Reply-To: <ca54ab04-9d70-cdc0-d09f-6609e9d43971@HIDDEN> (Konstantin
 Kharlamov's message of "Sun, 3 Feb 2019 21:09:48 +0300")
Message-ID: <874l3vrv0s.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.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
 @@CONTACT_ADDRESS@@ for details.
 Content preview: Konstantin Kharlamov <hi-angel@HIDDEN> writes: > By
 default
 the underscore "_" symbol is not being counted as part of a > word, even
 though I have never met a language where it's a separate > entity. 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 34301
Cc: 34301 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Konstantin Kharlamov <hi-angel@HIDDEN> writes:

> By default the underscore "_" symbol is not being counted as part of a
> word, even though I have never met a language where it's a separate
> entity.

In natural languages it's usually not word-consistent.

> This means e.g. that upon opening a file one is never being
> able to "search for word_wth_underscores under cursor", unless they
> modify current table.

Any programming language mode sets _ to be part of words, surely?  If
not that's a bug in that mode?  What modes do you see this in?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#34301; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 3 Feb 2019 18:10:19 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Feb 03 13:10:18 2019
Received: from localhost ([127.0.0.1]:57751 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1gqMDh-0000K5-VC
	for submit <at> debbugs.gnu.org; Sun, 03 Feb 2019 13:10:18 -0500
Received: from eggs.gnu.org ([209.51.188.92]:40103)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <hi-angel@HIDDEN>) id 1gqMDe-0000Jo-UC
 for submit <at> debbugs.gnu.org; Sun, 03 Feb 2019 13:10:16 -0500
Received: from lists.gnu.org ([209.51.188.17]:35853)
 by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32)
 (Exim 4.71) (envelope-from <hi-angel@HIDDEN>) id 1gqMDY-0002Py-Rz
 for submit <at> debbugs.gnu.org; Sun, 03 Feb 2019 13:10:09 -0500
Received: from eggs.gnu.org ([209.51.188.92]:54483)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <hi-angel@HIDDEN>) id 1gqMDX-0007kR-TQ
 for bug-gnu-emacs@HIDDEN; Sun, 03 Feb 2019 13:10:08 -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.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM,
 URIBL_BLOCKED autolearn=disabled version=3.3.2
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <hi-angel@HIDDEN>) id 1gqMDV-0002PK-VK
 for bug-gnu-emacs@HIDDEN; Sun, 03 Feb 2019 13:10:07 -0500
Received: from forward102o.mail.yandex.net ([2a02:6b8:0:1a2d::602]:42094)
 by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
 (Exim 4.71) (envelope-from <hi-angel@HIDDEN>) id 1gqMDS-0002MU-2q
 for bug-gnu-emacs@HIDDEN; Sun, 03 Feb 2019 13:10:04 -0500
Received: from mxback22g.mail.yandex.net (mxback22g.mail.yandex.net
 [IPv6:2a02:6b8:0:1472:2741:0:8b7:322])
 by forward102o.mail.yandex.net (Yandex) with ESMTP id D10CF6680A97
 for <bug-gnu-emacs@HIDDEN>; Sun,  3 Feb 2019 21:09:55 +0300 (MSK)
Received: from smtp3p.mail.yandex.net (smtp3p.mail.yandex.net
 [2a02:6b8:0:1472:2741:0:8b6:8])
 by mxback22g.mail.yandex.net (nwsmtp/Yandex) with ESMTP id mHAqthAzEY-9tVu3uDl;
 Sun, 03 Feb 2019 21:09:55 +0300
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail;
 t=1549217395; bh=0FeB/1yZnNin5nK5746Ff/OkNi62egcbWlKHbFTcyu4=;
 h=To:From:Subject:Message-ID:Date;
 b=Kq76xMXBUTt1xe5+BMKr8BgWCC3iEJbPpQAiCe0zxjl0FCH9RQ74PrKwrlA3z2JwN
 qr/D7fw9ycPArRE93dKOxPczooAyphWBnlNp9YKktBEuYfZioGA/NGgME6I9fDFXu6
 FWJ0WZ2E+Cv/rYB0w8GsGWJgNsdc3jr8RhQe4W1E=
Authentication-Results: mxback22g.mail.yandex.net;
 dkim=pass header.i=@yandex.ru
Received: by smtp3p.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id
 TnzutkAqYC-9taSlYmi; Sun, 03 Feb 2019 21:09:55 +0300
 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
 (Client certificate not present)
To: bug-gnu-emacs@HIDDEN
From: Konstantin Kharlamov <hi-angel@HIDDEN>
Subject: Unable to make underscore part of a word everywhere
Message-ID: <ca54ab04-9d70-cdc0-d09f-6609e9d43971@HIDDEN>
Date: Sun, 3 Feb 2019 21:09:48 +0300
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101
 Thunderbird/60.4.0
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
X-Received-From: 2a02:6b8:0:1a2d::602
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x
X-Spam-Score: 1.0 (+)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.0 (/)

By default the underscore "_" symbol is not being counted as part of a 
word, even though I have never met a language where it's a separate 
entity. This means e.g. that upon opening a file one is never being able 
to "search for word_wth_underscores under cursor", unless they modify 
current table. This problem haunts many people, e.g. this question has 
5576 views for 3 years 11 months 
https://emacs.stackexchange.com/questions/9583/how-to-treat-underscore-as-part-of-the-word

Known workarounds:
	1. Modify syntax table for every mode you happened to stumble upon.
	2. Use superword-mode

Why workarounds are bad:

	1. To make it work one has to search for syntax table name of the 
current mode, and then to modify config file accordingly, every time a 
new mode is being met. That's a lot of actions and research overall, a 
bloating config file; and also lots of work duplication by many Emacs users.
	2. superword-mode doesn't do anything to syntax table, and in 
particular doesn't work with evil-mode.

------

It would be great if Emacs has added a function or what not to just keep 
underscore as part of a word for all syntax tables by default.




Acknowledgement sent to Konstantin Kharlamov <hi-angel@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#34301; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Tue, 9 Jul 2019 18:15:01 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.