From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.bugs Subject: bug#25626: 25.1; doc of `bufferpos-to-filepos' for type `exact' Date: Sun, 5 Feb 2017 10:58:24 -0800 (PST) Message-ID: References: <8d705983-882e-48fb-a171-3fa9f025ac4f@default> <83tw887ahx.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1486321153 9509 195.159.176.226 (5 Feb 2017 18:59:13 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 5 Feb 2017 18:59:13 +0000 (UTC) Cc: 25626@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Feb 05 19:59:09 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1caS1k-0002Ej-R0 for geb-bug-gnu-emacs@m.gmane.org; Sun, 05 Feb 2017 19:59:09 +0100 Original-Received: from localhost ([::1]:44158 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1caS1n-0003ph-9K for geb-bug-gnu-emacs@m.gmane.org; Sun, 05 Feb 2017 13:59:11 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:57559) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1caS1h-0003pc-O9 for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2017 13:59:06 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1caS1e-0008Fg-Gb for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2017 13:59:05 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:58694) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1caS1e-0008FX-Da for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2017 13:59:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1caS1e-0000mK-4J for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2017 13:59:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Drew Adams Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 05 Feb 2017 18:59:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 25626 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 25626-submit@debbugs.gnu.org id=B25626.14863211162957 (code B ref 25626); Sun, 05 Feb 2017 18:59:02 +0000 Original-Received: (at 25626) by debbugs.gnu.org; 5 Feb 2017 18:58:36 +0000 Original-Received: from localhost ([127.0.0.1]:56893 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1caS1E-0000lc-2f for submit@debbugs.gnu.org; Sun, 05 Feb 2017 13:58:36 -0500 Original-Received: from userp1040.oracle.com ([156.151.31.81]:20714) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1caS1C-0000lQ-8P for 25626@debbugs.gnu.org; Sun, 05 Feb 2017 13:58:34 -0500 Original-Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by userp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id v15IwQvG009164 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sun, 5 Feb 2017 18:58:27 GMT Original-Received: from userv0121.oracle.com (userv0121.oracle.com [156.151.31.72]) by userv0022.oracle.com (8.14.4/8.14.4) with ESMTP id v15IwQxI023674 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sun, 5 Feb 2017 18:58:26 GMT Original-Received: from abhmp0004.oracle.com (abhmp0004.oracle.com [141.146.116.10]) by userv0121.oracle.com (8.14.4/8.13.8) with ESMTP id v15IwPa1031032; Sun, 5 Feb 2017 18:58:25 GMT In-Reply-To: <83tw887ahx.fsf@gnu.org> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 12.0.6753.5000 (x86)] X-Source-IP: userv0022.oracle.com [156.151.31.74] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:128997 Archived-At: > > =E2=80=98exact=E2=80=99, in which case we may end up re-(en/de)coding= a large > > part of the file/buffer. > > > > And (elisp) `Text Representations' says this: > > > > =E2=80=98exact=E2=80=99 > > The result must be accurate. The function may need to encode > > and decode a large part of the buffer. > > > > If I understand the code right, I think both of these are misleading. > > They can give the impression that the text in the region can have its > > encoding changed in its buffer. >=20 > I don't understand how you get that impression. You do know that > encoding text and then decoding it back produces the same text as was > there originally, right? >=20 > This text simply says that this option might be computationally > expensive. If that's the intent then say that. And I think it is the intent, hence this bug: please just say that. Saying "we may end up re-(en/de)coding" and "may need to encode and decode" does _not_ specify that the text is encoded _and then_ decoded back again, resulting in no change to the buffer. And the former means re-encode OR re-decode, not AND.) And in fact, IIUC, the text is encoded to a separate buffer (arg DESTINATION of `encode-coding-region'); it is not encoded in the original buffer - the text in that buffer is unaffected, and not because it is encoded and then decoded back. But perhaps I misunderstand this part. [There are also typos in the doc string of `encode-coding-region': "Optional 4th arguments" should be "Optional 4th argument" and "is replace by" should be "is replaced by".]