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 09:20:13 -0800 (PST) Message-ID: <8d705983-882e-48fb-a171-3fa9f025ac4f@default> 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 1486315277 12009 195.159.176.226 (5 Feb 2017 17:21:17 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 5 Feb 2017 17:21:17 +0000 (UTC) To: 25626@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Feb 05 18:21:11 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 1caQUs-0002gR-Sw for geb-bug-gnu-emacs@m.gmane.org; Sun, 05 Feb 2017 18:21:07 +0100 Original-Received: from localhost ([::1]:43935 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1caQUy-0007R3-Ds for geb-bug-gnu-emacs@m.gmane.org; Sun, 05 Feb 2017 12:21:12 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:42369) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1caQUs-0007Ql-1o for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2017 12:21:06 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1caQUo-0002hQ-RH for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2017 12:21:06 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:58637) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1caQUo-0002hM-O3 for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2017 12:21:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1caQUo-0006xZ-Iy for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2017 12:21: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 17:21:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 25626 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.148631523026686 (code B ref -1); Sun, 05 Feb 2017 17:21:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 5 Feb 2017 17:20:30 +0000 Original-Received: from localhost ([127.0.0.1]:56836 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1caQUH-0006wM-LI for submit@debbugs.gnu.org; Sun, 05 Feb 2017 12:20:29 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:51331) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1caQUF-0006w9-SZ for submit@debbugs.gnu.org; Sun, 05 Feb 2017 12:20:28 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1caQU9-0002cl-Vh for submit@debbugs.gnu.org; Sun, 05 Feb 2017 12:20:22 -0500 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:43116) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1caQU9-0002cP-SW for submit@debbugs.gnu.org; Sun, 05 Feb 2017 12:20:21 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:42295) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1caQU8-0007LJ-TS for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2017 12:20:21 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1caQU5-0002ZB-Mj for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2017 12:20:20 -0500 Original-Received: from aserp1040.oracle.com ([141.146.126.69]:19659) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1caQU5-0002YQ-CT for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2017 12:20:17 -0500 Original-Received: from aserv0021.oracle.com (aserv0021.oracle.com [141.146.126.233]) by aserp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id v15HKEgd015905 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Sun, 5 Feb 2017 17:20:14 GMT Original-Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by aserv0021.oracle.com (8.13.8/8.14.4) with ESMTP id v15HKE3V025151 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Sun, 5 Feb 2017 17:20:14 GMT Original-Received: from abhmp0004.oracle.com (abhmp0004.oracle.com [141.146.116.10]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id v15HKEYR024411 for ; Sun, 5 Feb 2017 17:20:14 GMT 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: aserv0021.oracle.com [141.146.126.233] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x 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:128988 Archived-At: The doc string says this: =E2=80=98exact=E2=80=99, in which case we may end up re-(en/de)coding a l= arge 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. But when `bufferpos-to-filepos' encodes some text it puts the resulting text in a different, temporary buffer, and returns its position - the original text (in the original buffer) does not have its encoding changed. Please consider clarifying this, so that it lets users know that the encoding cost of `exact' is only one of performance and that the buffer text is not changed in any way (in particular, its encoding is not changed). Or if I'm mistaken, and it does possibly change the encoding of some of the buffer text, then please consider clarifying the doc to state this explicitly. In other words, please elaborate on (clarify) what is meant by "may need to encode and decode a large part of the buffer" and "may end up re-(en/de)coding a large part of the file/buffer". In GNU Emacs 25.1.1 (x86_64-w64-mingw32) of 2016-11-15 Windowing system distributor `Microsoft Corp.', version 6.1.7601 Configured using: `configure --without-dbus --without-compress-install 'CFLAGS=3D-O2 -static -g3''