From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Nikolay Kudryavtsev Newsgroups: gmane.emacs.bugs Subject: bug#23097: 24.5; ispell.el: lines with both CASECHARS and NOT-CASECHARS get sent to the spell checker Date: Wed, 14 Oct 2020 22:20:08 +0300 Message-ID: <32dfc219-ac9c-8d9a-3140-d23977c8836c@gmail.com> References: <56F2DC47.2090600@gmail.com> <83fuvh2gwd.fsf@gnu.org> <83bljbkhrh.fsf@gnu.org> <5fe8e18f-efb4-4f9b-fd85-0cb4eccc58b4@gmail.com> <83eeo5gr8l.fsf@gnu.org> <08f3ac29-761c-ced7-1e2f-0f643512b986@gmail.com> <83mu0q132o.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7950"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.12.1 Cc: stefan@marxist.se, 23097@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Oct 14 21:21:11 2020 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 1kSmKl-0001wi-6t for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 14 Oct 2020 21:21:11 +0200 Original-Received: from localhost ([::1]:46478 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kSmKk-00086R-6L for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 14 Oct 2020 15:21:10 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:41344) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kSmKc-00085g-Sf for bug-gnu-emacs@gnu.org; Wed, 14 Oct 2020 15:21:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:41472) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kSmKc-0001l2-Ha for bug-gnu-emacs@gnu.org; Wed, 14 Oct 2020 15:21:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kSmKc-0003pX-CM for bug-gnu-emacs@gnu.org; Wed, 14 Oct 2020 15:21:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Nikolay Kudryavtsev Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 14 Oct 2020 19:21:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 23097 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: moreinfo notabug Original-Received: via spool by 23097-submit@debbugs.gnu.org id=B23097.160270321814650 (code B ref 23097); Wed, 14 Oct 2020 19:21:02 +0000 Original-Received: (at 23097) by debbugs.gnu.org; 14 Oct 2020 19:20:18 +0000 Original-Received: from localhost ([127.0.0.1]:53018 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kSmJu-0003oE-DA for submit@debbugs.gnu.org; Wed, 14 Oct 2020 15:20:18 -0400 Original-Received: from mail-lj1-f172.google.com ([209.85.208.172]:45605) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kSmJt-0003o1-5P for 23097@debbugs.gnu.org; Wed, 14 Oct 2020 15:20:17 -0400 Original-Received: by mail-lj1-f172.google.com with SMTP id a4so579523lji.12 for <23097@debbugs.gnu.org>; Wed, 14 Oct 2020 12:20:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:subject:to:cc:references:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding:content-language; bh=UNMJE3pqezUDdlqlMllO4ke0xor7x7DDHEFCktkfvlE=; b=tRk3JOkjrH9VhjkIdgdG2oL6haO4/J5+wgWRHyjNFAxmaXsc8HorwsB9KK7SnJWcwf PV/kZzMA7J3zTLQH2LLxkoee2lcrZAgsh2VP4+ihnLc8zLdUo5x32UUABQWSzwBEtCRn uJoDYRgvUUUr6JL04PgOXjkhcp/vodTtbP31RgdR6oMb6xrD6kv5YEUbP8Brjw+/mALP P9LMndC/j3NPiI2cb1RIq1PgWxaAN1ylDTaN9ljhhtzUOJZ2bV2kialG4fZwVW7Cael3 53vi4LvbvOM+GxRdZ5aoilBow/HnZgemwnM4Ii3gTJ/JpvRQ1FaoF+qZ2iv1TP1uXaox 65tQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:subject:to:cc:references:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=UNMJE3pqezUDdlqlMllO4ke0xor7x7DDHEFCktkfvlE=; b=Pc0FaH5n5ZuJPH5Mk95J58gjtpb5r9PeTWKMcNM42xY2+dUR1KmyCK4xGbr3kh0FfL lWeApmp0wp4Oy+EpV+cM/hRP8/Hpw6Oua/t04L37ckFn06G38lWKWL448bWWbpLM0eVA GSn4wXTOJaWiUndD2IG4PqMSo9RBYfDsvb9VkF87Jra+gYLMK2u5cWiy0XRYF+KrnzUB PHRh2tXNNN31+Q/n8mSV8emnBaZIFwXs0kcaUQlxYw79Asz+WQzM64hWX0DMHgJZQ2UD Eh3msjBR9lmnOUHMgTckgkwi+XGgH4Nq9AfynQUGFZqNfW+69tYn7oXROiVF0yInkJR3 7Jdw== X-Gm-Message-State: AOAM532Hq90yL+CRfvc0ZWjA1TyDY5lvZrGPk5nLhJg9luO76i2aiMva UvsPIXj18ypadJY2EID2nXS4H+v0VgQOqA== X-Google-Smtp-Source: ABdhPJy5YQBnylpOTI3Cxl6f90D3EsetvDYJ3M6+RzO2T9x1nE63BRR/MrbKYYkjkY26XjTw5dah1w== X-Received: by 2002:a2e:2e1a:: with SMTP id u26mr56263lju.295.1602703210438; Wed, 14 Oct 2020 12:20:10 -0700 (PDT) Original-Received: from [192.168.1.72] (128-69-156-0.broadband.corbina.ru. [128.69.156.0]) by smtp.gmail.com with ESMTPSA id i124sm72160lfd.236.2020.10.14.12.20.09 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 14 Oct 2020 12:20:09 -0700 (PDT) X-Google-Original-From: Nikolay Kudryavtsev In-Reply-To: <83mu0q132o.fsf@gnu.org> Content-Language: en-US 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:190517 Archived-At: The whole ispell-dictionary-alist structure implies that matching would be done word by word. And looking into the dictionary setup is the first thing ispell.el user would do. Apart from NOT-CASECHARS it also has this element: > OTHERCHARS is a regexp of characters in the NOT-CASECHARS set but > which can be > used to construct words in some special way.  If OTHERCHARS characters > follow > and precede characters from CASECHARS, they are parsed as part of a word, > otherwise they become word-breaks... Basically presence of both NOT-CASECHARS and OTHERCHARS implies that ispell.el does strict word by word matching. If we're just sending any line that contains a CASECHARS match, we don't really need either of them, since we can just match by CASECHARS alone and then send the line. Oh, and there's another thing. Ispell.el actually does word by word search, but only on resume. Try my recipe again, just make the last line of spellchecked buffer to look like "doh kat". Then suspend the spellcheck after the first line and resume it with C-u M-$. You'd see that it skips the last line "doh" fine in this scenario. But then it suffers from the word mix problem described by Eli: spellchecking dohkat" and "katdoh" results in kat alone being sent. Thinking a bit more about this word mix problem, seems like it's not as simple to fix it as I thought in my previous letter, since we need some list of legitimate word separators for each language. -- Best Regards, Nikolay Kudryavtsev