From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?Q?Andr=C3=A9?= A. Gomes Newsgroups: gmane.emacs.bugs Subject: bug#52331: M-$ doesn't respect subword mode Date: Mon, 06 Dec 2021 17:21:28 +0000 Message-ID: <87mtldy7hj.fsf@gmail.com> References: <87sfv5y9ng.fsf@gmail.com> <83h7bl1y1r.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="22483"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) Cc: 52331@debbugs.gnu.org, pogonyshev@gmail.com To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Dec 06 18:22:47 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 1muHhM-0005Zm-NG for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 06 Dec 2021 18:22:44 +0100 Original-Received: from localhost ([::1]:46474 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1muHhL-0002hy-KX for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 06 Dec 2021 12:22:43 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:43716) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1muHgg-00028v-57 for bug-gnu-emacs@gnu.org; Mon, 06 Dec 2021 12:22:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:51985) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1muHgf-00014d-TR for bug-gnu-emacs@gnu.org; Mon, 06 Dec 2021 12:22:01 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1muHgf-0000uN-OK for bug-gnu-emacs@gnu.org; Mon, 06 Dec 2021 12:22:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: =?UTF-8?Q?Andr=C3=A9?= A. Gomes Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 06 Dec 2021 17:22:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 52331 X-GNU-PR-Package: emacs Original-Received: via spool by 52331-submit@debbugs.gnu.org id=B52331.16388113013451 (code B ref 52331); Mon, 06 Dec 2021 17:22:01 +0000 Original-Received: (at 52331) by debbugs.gnu.org; 6 Dec 2021 17:21:41 +0000 Original-Received: from localhost ([127.0.0.1]:35296 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1muHgK-0000ta-T7 for submit@debbugs.gnu.org; Mon, 06 Dec 2021 12:21:41 -0500 Original-Received: from mail-wr1-f44.google.com ([209.85.221.44]:37836) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1muHgJ-0000tO-9p for 52331@debbugs.gnu.org; Mon, 06 Dec 2021 12:21:40 -0500 Original-Received: by mail-wr1-f44.google.com with SMTP id d9so23971235wrw.4 for <52331@debbugs.gnu.org>; Mon, 06 Dec 2021 09:21:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=+6UBTZ37nVd70Yl1W5yk43tEbnQ/MbkRACDlPpk08sQ=; b=E4Bwbjm804hcah22D4Vxn54D9AN3jRDmv4N1aHiWoZ0JThPWuRDNTl1GBoHg+CK+nB zBmyjQqEGI/w0eSkBKwXldAtJjTt3xGrkf0W/u3zyn24Ts3iBByfxjOjtqrP2ekaUyxZ q6lv6XZ7NTfmhVEhCLtyRHzLX0gYT3uYNWF/wPpx708KlsHjKl+hwywz9aVzTLAVyvHB hlggejvyHNJT+EeF5TUuK4fTHaM9oBMvWsNESOITZ+ltxeTvJtRbIoF/hv2WmzRTClKo zAPIRszhyUXrrrdfUCp3a9Q5rbyU5/nOvnjDkdMUHfKbTEnD7F4xtl6pPOehIRv9535+ Zymg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=+6UBTZ37nVd70Yl1W5yk43tEbnQ/MbkRACDlPpk08sQ=; b=atwOttK7wIzQ1DhTitCdYQcPfD50c4NZaJwDcGrI8SKyKLcWCxZCcXHRfjvYC92inR gKXADQZjh/PNvMpJY/9Zg3OQH9AzQi+9Pj3in32Pz87lksPKh+tSGbeSfOXttzXrkQPR ZuMPBydER6d8JbEx26jvMwaWXp+mw9PnlRbmXlZ4DByAbY7rmHyWgynVAJy6cAIZItWp 6JOLrA/7sSVvBizXXs8tpekjyAYQ9rSBfihrIn5rVbXXggXyzrMCCl6gVelr18nGSahu ItpF7lP5mKxDb3i419AR2UajE6j9kYnUIe4XQ/PnANm93RiQXb9hANehnAz0IEm5Qodi cqhw== X-Gm-Message-State: AOAM533zaHl4xiLmKqaRpjDfYU2tAoXCDtWrrjmSpFOrZbAP4ePQbUYF sHPUqUv839UHPX93zrQeNo4wEWLjAQM= X-Google-Smtp-Source: ABdhPJyLSGx5ia7PAUVWptIAPokO8sLOpbFSxWffyoWJlYRgAzEu0hyKEpxSLOw8Yw/v5nQ2BLRU5g== X-Received: by 2002:adf:f207:: with SMTP id p7mr44493734wro.173.1638811293343; Mon, 06 Dec 2021 09:21:33 -0800 (PST) Original-Received: from guix-xps13 ([2001:818:daa9:6700:462d:384e:6de8:4a1c]) by smtp.gmail.com with ESMTPSA id e12sm15174121wrq.20.2021.12.06.09.21.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Dec 2021 09:21:32 -0800 (PST) In-Reply-To: <83h7bl1y1r.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 06 Dec 2021 18:46:24 +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:221769 Archived-At: Eli Zaretskii writes: >> However, and the Emacs maintainers will probably agree, the >> responsibility of sending the "right" word to the ispell sub-process >> should be on Emacs' side. I.e., when subword-mode is on, there should >> be a call to word-at-point before sending it to the spell checker. > > It's not that easy, unfortunately. ispell.el has its own rules for > what is a word, and the rules aren't static, they are determined > dynamically by the definition of the dictionary. That's because of at > least 2 reasons: (1) the rules must match what the dictionary > considers a word, and (2) spell-checking is expected to work in > buffers that mix several languages, so the rules need to be sensitive > to the language of the dictionary and reject "words" whose letters are > not part of the language. Correct, my comment was over simplistic. But I don't see where my reasoning fails. I can't think of an example where calling word-at-point before the ispell rules kick in would make harm. What am I missing? > So perhaps a better approach is to teach subword-mode about the word > rules of ispell.el, not the other way around. Patches welcome. I don't see how this could help. Care to expand a bit? -- Andr=C3=A9 A. Gomes "Free Thought, Free World"