From unknown Sun Jun 22 00:00:23 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#13033 <13033@debbugs.gnu.org> To: bug#13033 <13033@debbugs.gnu.org> Subject: Status: 24.3.50; regression: read-file-name-internal handles "~" wrong Reply-To: bug#13033 <13033@debbugs.gnu.org> Date: Sun, 22 Jun 2025 07:00:23 +0000 retitle 13033 24.3.50; regression: read-file-name-internal handles "~" wrong reassign 13033 emacs submitter 13033 "Drew Adams" severity 13033 minor thanks From debbugs-submit-bounces@debbugs.gnu.org Thu Nov 29 16:47:05 2012 Received: (at submit) by debbugs.gnu.org; 29 Nov 2012 21:47:05 +0000 Received: from localhost ([127.0.0.1]:45663 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeBwn-0003wM-6p for submit@debbugs.gnu.org; Thu, 29 Nov 2012 16:47:05 -0500 Received: from eggs.gnu.org ([208.118.235.92]:39469) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeBwl-0003wF-5r for submit@debbugs.gnu.org; Thu, 29 Nov 2012 16:47:04 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TeBum-0006iH-C8 for submit@debbugs.gnu.org; Thu, 29 Nov 2012 16:45:01 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_HI, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:40234) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TeBum-0006iD-8x for submit@debbugs.gnu.org; Thu, 29 Nov 2012 16:45:00 -0500 Received: from eggs.gnu.org ([208.118.235.92]:36089) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TeBul-0003YG-DB for bug-gnu-emacs@gnu.org; Thu, 29 Nov 2012 16:45:00 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TeBuk-0006i2-El for bug-gnu-emacs@gnu.org; Thu, 29 Nov 2012 16:44:59 -0500 Received: from aserp1040.oracle.com ([141.146.126.69]:47573) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TeBuk-0006hx-8A for bug-gnu-emacs@gnu.org; Thu, 29 Nov 2012 16:44:58 -0500 Received: from acsinet21.oracle.com (acsinet21.oracle.com [141.146.126.237]) by aserp1040.oracle.com (Sentrion-MTA-4.2.2/Sentrion-MTA-4.2.2) with ESMTP id qATLisTi027668 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Thu, 29 Nov 2012 21:44:55 GMT Received: from acsmt357.oracle.com (acsmt357.oracle.com [141.146.40.157]) by acsinet21.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id qATLisJq015805 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Thu, 29 Nov 2012 21:44:54 GMT Received: from abhmt112.oracle.com (abhmt112.oracle.com [141.146.116.64]) by acsmt357.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id qATLisTV022153 for ; Thu, 29 Nov 2012 15:44:54 -0600 Received: from dradamslap1 (/130.35.178.8) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Thu, 29 Nov 2012 13:44:53 -0800 From: "Drew Adams" To: Subject: 24.3.50; regression: read-file-name-internal handles "~" wrong Date: Thu, 29 Nov 2012 13:44:52 -0800 Message-ID: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 Thread-Index: Ac3OesOfsOb5FGyzTcmPSnH1D7DocA== X-Source-IP: acsinet21.oracle.com [141.146.126.237] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -3.4 (---) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.1 (------) This is on Windows. I have Cygwin installed, but that should not affect how Emacs interprets `~'. My `user-login-name' is "dradams". My `user-full-name' is "". In this Emacs version, (read-file-name-internal "~" 'file-exists-p nil) returns "~/dradams/". That is wrong. Not only is there no such directory as ~/dradams/". But my HOME environment variable is defined as "c:\\". In 24.2 and in all previous Emacs versions (with the 2nd arg a dir, as needed), (read-file-name-internal "~" 'file-exists-p nil) returns nil. Please revert the code that causes this regression. In GNU Emacs 24.3.50.1 (i386-mingw-nt5.1.2600) of 2012-11-19 on MS-W7-DANI Bzr revision: 110950 monnier@iro.umontreal.ca-20121119182725-5p6w4wjimm7epggr Windowing system distributor `Microsoft Corp.', version 5.1.2600 Configured using: `configure --with-gcc (4.7) --no-opt --enable-checking --cflags -Ic:/emacs/libs/libXpm-3.5.10/include -Ic:/emacs/libs/libXpm-3.5.10/src -Ic:/emacs/libs/libpng-1.2.37-lib/include -Ic:/emacs/libs/zlib-1.2.5 -Ic:/emacs/libs/giflib-4.1.4-1-lib/include -Ic:/emacs/libs/jpeg-6b-4-lib/include -Ic:/emacs/libs/tiff-3.8.2-1-lib/include -Ic:/emacs/libs/libxml2-2.7.8-w32-bin/include/libxml2 -Ic:/emacs/libs/gnutls-3.0.9-w32-bin/include -Ic:/emacs/libs/libiconv-1.9.2-1-lib/include' From debbugs-submit-bounces@debbugs.gnu.org Thu Nov 29 19:01:15 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 00:01:15 +0000 Received: from localhost ([127.0.0.1]:45706 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeE2d-00070n-A0 for submit@debbugs.gnu.org; Thu, 29 Nov 2012 19:01:15 -0500 Received: from mail-ee0-f44.google.com ([74.125.83.44]:45031) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeE2b-00070g-85 for 13033@debbugs.gnu.org; Thu, 29 Nov 2012 19:01:14 -0500 Received: by mail-ee0-f44.google.com with SMTP id b47so9379705eek.3 for <13033@debbugs.gnu.org>; Thu, 29 Nov 2012 15:59:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=5IjiRDpJsEtFZ6IHAR/AuvNN9r66km6mZxWvYK/DknM=; b=qlHKDiPU3S+NruwhLUN+ai/9Ggs1rzZMXzNc6u8pOQKeP79gVhkXPNw4j867ex3AG/ T0dzbOXxzhtGnvwTAOoRK+WY4af7BuDIUDKAqDl/bLACj/3+iF4iJ0e8Ez65x8zs5+rB 2Hm+AN/Hr4OowaQjG+LJj+589H4iPBbhoJPGL2PuxepI2BV6KpFQjS8c1N+9HlqfI1Nr 4saPij8jftZHy3xaPO1fXsNmAb6DhSXp18VljmVhKwXDT2GymQ2sFY1k4rU9gj3j8QHI pSwyemDUF2rthmnztK0bn0KMIw4Jgq+SFKuQFxseTTQ86XdSPONuonWflsTAGijrfOuY Yl8g== Received: by 10.14.5.71 with SMTP id 47mr15229480eek.1.1354233550204; Thu, 29 Nov 2012 15:59:10 -0800 (PST) MIME-Version: 1.0 Received: by 10.223.4.209 with HTTP; Thu, 29 Nov 2012 15:58:29 -0800 (PST) In-Reply-To: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> From: Juanma Barranquero Date: Fri, 30 Nov 2012 00:58:29 +0100 Message-ID: Subject: Re: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong To: Drew Adams Content-Type: text/plain; charset=UTF-8 X-Spam-Score: 0.1 (/) X-Debbugs-Envelope-To: 13033 Cc: 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 0.1 (/) On Thu, Nov 29, 2012 at 10:44 PM, Drew Adams wrote: > In this Emacs version, > (read-file-name-internal "~" 'file-exists-p nil) returns "~/dradams/". read-file-name-internal's docstring clearly says: "Internal subroutine for `read-file-name'. Do not call this." So it's not a regression as long as the public interface of minibuffer.el is working as expected. J From debbugs-submit-bounces@debbugs.gnu.org Thu Nov 29 22:58:50 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 03:58:50 +0000 Received: from localhost ([127.0.0.1]:45857 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeHkX-0005mu-S8 for submit@debbugs.gnu.org; Thu, 29 Nov 2012 22:58:50 -0500 Received: from ironport2-out.teksavvy.com ([206.248.154.182]:28747) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeHkW-0005mo-Mq for 13033@debbugs.gnu.org; Thu, 29 Nov 2012 22:58:49 -0500 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ai0FAG6Zu09FxKh9/2dsb2JhbABEsEiDSYEIghUBAQQBViMFCws0EhQYDSSIHAW6CZBEA4hCmnGBWIMH X-IronPort-AV: E=Sophos;i="4.75,637,1330923600"; d="scan'208";a="208794642" Received: from 69-196-168-125.dsl.teksavvy.com (HELO pastel.home) ([69.196.168.125]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 29 Nov 2012 22:56:45 -0500 Received: by pastel.home (Postfix, from userid 20848) id 9D64759069; Thu, 29 Nov 2012 22:56:44 -0500 (EST) From: Stefan Monnier To: "Drew Adams" Subject: Re: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong Message-ID: References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> Date: Thu, 29 Nov 2012 22:56:44 -0500 In-Reply-To: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> (Drew Adams's message of "Thu, 29 Nov 2012 13:44:52 -0800") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.8 (/) X-Debbugs-Envelope-To: 13033 Cc: 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -0.0 (/) > In this Emacs version, > (read-file-name-internal "~" 'file-exists-p nil) returns "~/dradams/". > That is wrong. Not only is there no such directory as ~/dradams/". But > my HOME environment variable is defined as "c:\\". Can you tell me what happens when you do the following: (completion--embedded-envvar-table "~" 'file-exists-p nil) or (completion--file-name-table "~" 'file-exists-p nil) or (completion-file-name-table "~" 'file-exists-p nil) Stefan From debbugs-submit-bounces@debbugs.gnu.org Thu Nov 29 23:10:18 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 04:10:18 +0000 Received: from localhost ([127.0.0.1]:45861 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeHvd-00063J-Vw for submit@debbugs.gnu.org; Thu, 29 Nov 2012 23:10:18 -0500 Received: from aserp1040.oracle.com ([141.146.126.69]:30633) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeHvc-000639-5e for 13033@debbugs.gnu.org; Thu, 29 Nov 2012 23:10:17 -0500 Received: from ucsinet21.oracle.com (ucsinet21.oracle.com [156.151.31.93]) by aserp1040.oracle.com (Sentrion-MTA-4.2.2/Sentrion-MTA-4.2.2) with ESMTP id qAU48B8Y030243 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 30 Nov 2012 04:08:12 GMT Received: from acsmt356.oracle.com (acsmt356.oracle.com [141.146.40.156]) by ucsinet21.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id qAU48ANw024694 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 30 Nov 2012 04:08:10 GMT Received: from abhmt103.oracle.com (abhmt103.oracle.com [141.146.116.55]) by acsmt356.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id qAU489lc007932; Thu, 29 Nov 2012 22:08:09 -0600 Received: from dradamslap1 (/10.159.169.89) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Thu, 29 Nov 2012 20:08:09 -0800 From: "Drew Adams" To: "'Stefan Monnier'" References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> Subject: RE: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong Date: Thu, 29 Nov 2012 20:08:06 -0800 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 In-Reply-To: Thread-Index: Ac3Orrf84jbiOZRJRVmCRhy6KYl5AwAAQ6qA X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-Source-IP: ucsinet21.oracle.com [156.151.31.93] X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13033 Cc: 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) > Can you tell me what happens when you do the following: > > (completion--embedded-envvar-table "~" 'file-exists-p nil) nil > (completion--file-name-table "~" 'file-exists-p nil) "~dradams/" > (completion-file-name-table "~" 'file-exists-p nil) "~dradams/" All from emacs -Q. In Emacs 24.2 and 23.4 they all return nil. From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 30 08:13:41 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 13:13:41 +0000 Received: from localhost ([127.0.0.1]:46353 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeQPU-0003gw-SQ for submit@debbugs.gnu.org; Fri, 30 Nov 2012 08:13:41 -0500 Received: from mout.web.de ([212.227.17.12]:62502) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeQPS-0003gm-So for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 08:13:39 -0500 Received: from drachen.dragon ([82.113.121.35]) by smtp.web.de (mrweb001) with ESMTPA (Nemesis) id 0Ma2lb-1Tvpjq3dS3-00LxNJ; Fri, 30 Nov 2012 14:11:30 +0100 From: Michael Heerdegen To: Juanma Barranquero Subject: Re: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> Date: Fri, 30 Nov 2012 14:12:14 +0100 In-Reply-To: (Juanma Barranquero's message of "Fri, 30 Nov 2012 00:58:29 +0100") Message-ID: <87d2yvute9.fsf@web.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.90 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V02:K0:9ZG3PIETlAviyQZML2LZ/NwI9qQS2cWCB7/SVvmiCVc mqweT9OTLgFAPCi+yPXDdGGn5l9xtFMJFDot8F/Chmnj+odMrJ NUG77yO4MzIrZGNbUVIhN2UHj2TokxVq3AzGy3ZtuIsVINLauA iRQrQSr6EvLoynRtuUaSq8coF9ignZ0ymFtKUE4ML8hw8YULVi lCgvgo8JBPoFY2NNx5+8yCN4QFmFRvTmyvL2IZNyYs= X-Spam-Score: 1.2 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: Juanma Barranquero writes: > On Thu, Nov 29, 2012 at 10:44 PM, Drew Adams wrote: > > > In this Emacs version, > > (read-file-name-internal "~" 'file-exists-p nil) returns "~/dradams/". > > read-file-name-internal's docstring clearly says: "Internal > subroutine for `read-file-name'. Do not call this." [...] Content analysis details: (1.2 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (michael_heerdegen[at]web.de) 0.8 RCVD_IN_SORBS_WEB RBL: SORBS: sender is an abusable web server [82.113.121.35 listed in dnsbl.sorbs.net] -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [212.227.17.12 listed in list.dnswl.org] -0.4 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.5000] X-Debbugs-Envelope-To: 13033 Cc: 13033@debbugs.gnu.org, Drew Adams X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 1.2 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: Juanma Barranquero writes: > On Thu, Nov 29, 2012 at 10:44 PM, Drew Adams wrote: > > > In this Emacs version, > > (read-file-name-internal "~" 'file-exists-p nil) returns "~/dradams/". > > read-file-name-internal's docstring clearly says: "Internal > subroutine for `read-file-name'. Do not call this." [...] Content analysis details: (1.2 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.8 RCVD_IN_SORBS_WEB RBL: SORBS: sender is an abusable web server [82.113.121.35 listed in dnsbl.sorbs.net] -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [212.227.17.12 listed in list.dnswl.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (michael_heerdegen[at]web.de) -0.4 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.5000] Juanma Barranquero writes: > On Thu, Nov 29, 2012 at 10:44 PM, Drew Adams wrote: > > > In this Emacs version, > > (read-file-name-internal "~" 'file-exists-p nil) returns "~/dradams/". > > read-file-name-internal's docstring clearly says: "Internal > subroutine for `read-file-name'. Do not call this." I'm not sure if I understand the implications. I thought something like "Do not call this." is meant for the end users, but also for developers? Emacs is the "extensible ... editor". It is quite difficult for any developer to extend Emacs and contribute packages if we only allow the use of high-level public interface functions. I'm helping Drew to fix problems in Icicles. It was already hard to understand the not very lengthy documented new completion code. But if we are disallowed to use it, we had to stop to develop something like Icicles. If we start to change our habits and write Emacs in a way that essential primitives aren't allowed to be called by developers, this is the beginning of the end of extensibility. It is a bug if something like `read-file-name-internal' is not allowed to be called in third-party packages. At university I learned that writing software happens in a way that every function should have a clear specification for what it does/returns, and a documentation of this. Ok, I'm not that much a software developer that I would know if this is always necessary in that strong sense. But it would be helpful if the sources of Emacs (which is free software that may be used and modified by anyone) would be a bit more readable and reusable than the compiled byte-code. Michael. From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 30 08:58:13 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 13:58:13 +0000 Received: from localhost ([127.0.0.1]:46417 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeR6a-0004kR-C9 for submit@debbugs.gnu.org; Fri, 30 Nov 2012 08:58:12 -0500 Received: from mtaout22.012.net.il ([80.179.55.172]:59872) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeR6V-0004k3-GS for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 08:58:09 -0500 Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0MEA00J00ZXWJN00@a-mtaout22.012.net.il> for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 15:56:00 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MEB00INR01BTDG0@a-mtaout22.012.net.il>; Fri, 30 Nov 2012 15:56:00 +0200 (IST) Date: Fri, 30 Nov 2012 15:55:45 +0200 From: Eli Zaretskii Subject: Re: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong In-reply-to: <87d2yvute9.fsf@web.de> X-012-Sender: halo1@inter.net.il To: Michael Heerdegen Message-id: <8338zrurdq.fsf@gnu.org> References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> <87d2yvute9.fsf@web.de> X-Spam-Score: 1.5 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > From: Michael Heerdegen > Date: Fri, 30 Nov 2012 14:12:14 +0100 > Cc: 13033@debbugs.gnu.org > > Juanma Barranquero writes: > > > On Thu, Nov 29, 2012 at 10:44 PM, Drew Adams wrote: > > > > > In this Emacs version, > > > (read-file-name-internal "~" 'file-exists-p nil) returns "~/dradams/". > > > > read-file-name-internal's docstring clearly says: "Internal > > subroutine for `read-file-name'. Do not call this." > > I'm not sure if I understand the implications. I thought something like > "Do not call this." is meant for the end users, but also for developers? [...] Content analysis details: (1.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [80.179.55.172 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.5000] X-Debbugs-Envelope-To: 13033 Cc: lekktu@gmail.com, 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 1.5 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > From: Michael Heerdegen > Date: Fri, 30 Nov 2012 14:12:14 +0100 > Cc: 13033@debbugs.gnu.org > > Juanma Barranquero writes: > > > On Thu, Nov 29, 2012 at 10:44 PM, Drew Adams wrote: > > > > > In this Emacs version, > > > (read-file-name-internal "~" 'file-exists-p nil) returns "~/dradams/". > > > > read-file-name-internal's docstring clearly says: "Internal > > subroutine for `read-file-name'. Do not call this." > > I'm not sure if I understand the implications. I thought something like > "Do not call this." is meant for the end users, but also for developers? [...] Content analysis details: (1.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [80.179.55.172 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.5000] > From: Michael Heerdegen > Date: Fri, 30 Nov 2012 14:12:14 +0100 > Cc: 13033@debbugs.gnu.org > > Juanma Barranquero writes: > > > On Thu, Nov 29, 2012 at 10:44 PM, Drew Adams wrote: > > > > > In this Emacs version, > > > (read-file-name-internal "~" 'file-exists-p nil) returns "~/dradams/". > > > > read-file-name-internal's docstring clearly says: "Internal > > subroutine for `read-file-name'. Do not call this." > > I'm not sure if I understand the implications. I thought something like > "Do not call this." is meant for the end users, but also for developers? It means "don't call it from Lisp applications outside basic Lisp packages that come with Emacs." If that is a limitation, then I suggest to request additional APIs or extension of existing APIs, to cover the features which you miss in the current code base and that prompted you to use this function. > Emacs is the "extensible ... editor". It is quite difficult for any > developer to extend Emacs and contribute packages if we only allow the > use of high-level public interface functions. If that is true, then Emacs lacks some public APIs that should be added or extended. Using internal functions is not the way. > If we start to change our habits and write Emacs in a way that essential > primitives aren't allowed to be called by developers, this is the > beginning of the end of extensibility. Most primitives _are_ allowed to be called. But when you see something like "internal use only, don't call", that is not something you should ignore, because whoever wrote that had something serious in their minds. > It is a bug if something like `read-file-name-internal' is not > allowed to be called in third-party packages. Then please submit bug reports, asking for features that you cannot get from other APIs. > At university I learned that writing software happens in a way that > every function should have a clear specification for what it > does/returns, and a documentation of this. If they didn't teach you about the difference between internal APIs and public APIs, then it's too bad. Nevertheless, the distinction is part of our lives. Some languages have means to conceal private APIs from external applications, but C and Emacs Lisp don't. So we use whatever we got; please always assume that there are good reasons for that. (It is OK, of course, to question those reasons, but ignoring them is not wise, IMO.) From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 30 12:02:44 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 17:02:44 +0000 Received: from localhost ([127.0.0.1]:47220 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeTz9-0000h8-PA for submit@debbugs.gnu.org; Fri, 30 Nov 2012 12:02:44 -0500 Received: from relais.videotron.ca ([24.201.245.36]:32992) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeTz7-0000gz-NH for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 12:02:42 -0500 MIME-version: 1.0 Content-transfer-encoding: 7BIT Content-type: text/plain; CHARSET=US-ASCII Received: from ceviche.home ([24.201.208.110]) by VL-VM-MR004.ip.videotron.ca (Oracle Communications Messaging Exchange Server 7u4-22.01 64bit (built Apr 21 2011)) with ESMTP id <0MEB00KOB8KYW650@VL-VM-MR004.ip.videotron.ca> for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 12:00:35 -0500 (EST) Received: by ceviche.home (Postfix, from userid 20848) id A9E3366109; Fri, 30 Nov 2012 12:00:32 -0500 (EST) From: Stefan Monnier To: Drew Adams Subject: Re: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong Message-id: References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> Date: Fri, 30 Nov 2012 12:00:32 -0500 In-reply-to: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) X-Spam-Score: 1.6 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: >> Can you tell me what happens when you do the following: >> (completion--embedded-envvar-table "~" 'file-exists-p nil) > nil >> (completion--file-name-table "~" 'file-exists-p nil) > "~dradams/" >> (completion-file-name-table "~" 'file-exists-p nil) > "~dradams/" > All from emacs -Q. In Emacs 24.2 and 23.4 they all return nil. [...] Content analysis details: (1.6 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [24.201.245.36 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.5000] 0.1 HDRS_LCASE Odd capitalization of message header 0.0 T_MANY_HDRS_LCASE Odd capitalization of multiple message headers X-Debbugs-Envelope-To: 13033 Cc: 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 1.5 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: >> Can you tell me what happens when you do the following: >> (completion--embedded-envvar-table "~" 'file-exists-p nil) > nil >> (completion--file-name-table "~" 'file-exists-p nil) > "~dradams/" >> (completion-file-name-table "~" 'file-exists-p nil) > "~dradams/" > All from emacs -Q. In Emacs 24.2 and 23.4 they all return nil. [...] Content analysis details: (1.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [24.201.245.36 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.5000] >> Can you tell me what happens when you do the following: >> (completion--embedded-envvar-table "~" 'file-exists-p nil) > nil >> (completion--file-name-table "~" 'file-exists-p nil) > "~dradams/" >> (completion-file-name-table "~" 'file-exists-p nil) > "~dradams/" > All from emacs -Q. In Emacs 24.2 and 23.4 they all return nil. OK, that makes sense since older versions did not support user-name completion. Now you say that (read-file-name-internal "~" 'file-exists-p nil) returns "~/dradams/" and I can't understand where the additional slash comes from. Also arguably, "~/" should also be a completion candidate, so the above calls should not complete to "~dradams/" but to "~" (the common prefix between the two possible completions). Stefan From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 30 12:26:40 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 17:26:40 +0000 Received: from localhost ([127.0.0.1]:47254 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeUMJ-0001J2-CC for submit@debbugs.gnu.org; Fri, 30 Nov 2012 12:26:40 -0500 Received: from userp1040.oracle.com ([156.151.31.81]:24297) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeUMH-0001It-4Y for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 12:26:38 -0500 Received: from acsinet21.oracle.com (acsinet21.oracle.com [141.146.126.237]) by userp1040.oracle.com (Sentrion-MTA-4.2.2/Sentrion-MTA-4.2.2) with ESMTP id qAUHOSrS030686 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 30 Nov 2012 17:24:29 GMT Received: from acsmt356.oracle.com (acsmt356.oracle.com [141.146.40.156]) by acsinet21.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id qAUHOSaQ015337 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 30 Nov 2012 17:24:28 GMT Received: from abhmt103.oracle.com (abhmt103.oracle.com [141.146.116.55]) by acsmt356.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id qAUHORjB013558; Fri, 30 Nov 2012 11:24:28 -0600 Received: from dradamslap1 (/10.159.169.89) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Fri, 30 Nov 2012 09:24:27 -0800 From: "Drew Adams" To: "'Stefan Monnier'" References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> Subject: RE: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong Date: Fri, 30 Nov 2012 09:24:21 -0800 Message-ID: <409B80A02CEB4F14B201BE9F3D5EE93C@us.oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 In-Reply-To: Thread-Index: Ac3PHDgM4WMHgq0ZRbSL2O0FdJsHigAAlG9g X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-Source-IP: acsinet21.oracle.com [141.146.126.237] X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13033 Cc: 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) > OK, that makes sense since older versions did not support > user-name completion. Now you say that (read-file-name-internal "~" > 'file-exists-p nil) returns "~/dradams/" and I can't understand where > the additional slash comes from. > > Also arguably, "~/" should also be a completion candidate, so > the above calls should not complete to "~dradams/" but to "~" > (the common prefix between the two possible completions). I cannot speak to why the / is included or why ~ is not considered the common prefix. Whoever implemented this change might be able to answer that. To me, the important point in this bug report is that there is no such directory: ~/dradams/. And there is no such directory ~dradams either. Returning either of those as a valid completion for a file/dir name is just plain wrong, I think. There is a directory that corresponds to ~. It is the HOME (env var) directory, which in my case is c:\. Seems like perhaps something that might be relevant for Unix/GNU/Linux has been inappropriately applied to Windows too. Dunno. I do not see why user-name completion (whatever that might mean for Unix/GNU/Linux file-name completion) is involved at all on Windows. The user login name has nothing to do with the user's home directory. From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 30 13:47:02 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 18:47:02 +0000 Received: from localhost ([127.0.0.1]:47330 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeVc6-0003KF-FZ for submit@debbugs.gnu.org; Fri, 30 Nov 2012 13:47:02 -0500 Received: from relais.videotron.ca ([24.201.245.36]:10371) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeVc5-0003Ju-Dd for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 13:47:01 -0500 MIME-version: 1.0 Content-transfer-encoding: 7BIT Content-type: text/plain; CHARSET=US-ASCII Received: from ceviche.home ([24.201.208.110]) by VL-VM-MR005.ip.videotron.ca (Oracle Communications Messaging Exchange Server 7u4-22.01 64bit (built Apr 21 2011)) with ESMTP id <0MEB00101DEUF581@VL-VM-MR005.ip.videotron.ca> for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 13:44:54 -0500 (EST) Received: by ceviche.home (Postfix, from userid 20848) id DAE9C66109; Fri, 30 Nov 2012 13:44:53 -0500 (EST) From: Stefan Monnier To: Drew Adams Subject: Re: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong Message-id: References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> <409B80A02CEB4F14B201BE9F3D5EE93C@us.oracle.com> Date: Fri, 30 Nov 2012 13:44:53 -0500 In-reply-to: <409B80A02CEB4F14B201BE9F3D5EE93C@us.oracle.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) X-Spam-Score: 1.6 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: >> OK, that makes sense since older versions did not support >> user-name completion. Now you say that (read-file-name-internal "~" >> 'file-exists-p nil) returns "~/dradams/" and I can't understand where >> the additional slash comes from. >> Also arguably, "~/" should also be a completion candidate, so >> the above calls should not complete to "~dradams/" but to "~" >> (the common prefix between the two possible completions). [...] Content analysis details: (1.6 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [24.201.245.36 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.5000] 0.1 HDRS_LCASE Odd capitalization of message header 0.0 T_MANY_HDRS_LCASE Odd capitalization of multiple message headers X-Debbugs-Envelope-To: 13033 Cc: 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 1.5 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: >> OK, that makes sense since older versions did not support >> user-name completion. Now you say that (read-file-name-internal "~" >> 'file-exists-p nil) returns "~/dradams/" and I can't understand where >> the additional slash comes from. >> Also arguably, "~/" should also be a completion candidate, so >> the above calls should not complete to "~dradams/" but to "~" >> (the common prefix between the two possible completions). [...] Content analysis details: (1.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [24.201.245.36 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.4976] >> OK, that makes sense since older versions did not support >> user-name completion. Now you say that (read-file-name-internal "~" >> 'file-exists-p nil) returns "~/dradams/" and I can't understand where >> the additional slash comes from. >> Also arguably, "~/" should also be a completion candidate, so >> the above calls should not complete to "~dradams/" but to "~" >> (the common prefix between the two possible completions). > I cannot speak to why the / is included or why ~ is not considered the common > prefix. Then let me state it more clearly: Are you really sure that (read-file-name-internal "~" 'file-exists-p nil) returns "~/dradams/" even though (completion--file-name-table "~" 'file-exists-p nil) returns "~dradams/" ? I ask because read-file-name-internal is defined as: (defalias 'read-file-name-internal (completion-table-in-turn #'completion--embedded-envvar-table #'completion--file-name-table) And I don't see where/why completion-table-in-turn would add a /. I just want to make extra sure that that's indeed the problem, and not a simple typo. > And there is no such directory ~dradams either. Actually, there should be (in the same sense that there is a directory named ~, i.e. it's a shorthand expanded by Emacs, more specifically by `expand-file-name'). What does C-x C-f ~dradams/.emacs RET do? It should open your ~/.emacs file. > I do not see why user-name completion (whatever that might mean for > Unix/GNU/Linux file-name completion) is involved at all on Windows. The user > login name has nothing to do with the user's home directory. `expand-file-name's docstring says: An initial `~USER/' expands to USER's home directory. -- Stefan From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 30 14:03:46 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 19:03:46 +0000 Received: from localhost ([127.0.0.1]:47378 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeVsH-0003jd-25 for submit@debbugs.gnu.org; Fri, 30 Nov 2012 14:03:45 -0500 Received: from mtaout22.012.net.il ([80.179.55.172]:56539) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeVsD-0003jT-CK for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 14:03:43 -0500 Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0MEB00M00E1R9400@a-mtaout22.012.net.il> for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 21:01:24 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MEB00L9BE6BZY50@a-mtaout22.012.net.il>; Fri, 30 Nov 2012 21:01:24 +0200 (IST) Date: Fri, 30 Nov 2012 21:01:10 +0200 From: Eli Zaretskii Subject: Re: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong In-reply-to: X-012-Sender: halo1@inter.net.il To: Stefan Monnier Message-id: <83obieud8p.fsf@gnu.org> References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> X-Spam-Score: 1.5 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > From: Stefan Monnier > Date: Fri, 30 Nov 2012 12:00:32 -0500 > Cc: 13033@debbugs.gnu.org > > Now you say that (read-file-name-internal "~" 'file-exists-p nil) > returns "~/dradams/" and I can't understand where the additional > slash comes from. [...] Content analysis details: (1.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [80.179.55.172 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.4926] X-Debbugs-Envelope-To: 13033 Cc: 13033@debbugs.gnu.org, drew.adams@oracle.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 0.7 (/) > From: Stefan Monnier > Date: Fri, 30 Nov 2012 12:00:32 -0500 > Cc: 13033@debbugs.gnu.org > > Now you say that (read-file-name-internal "~" 'file-exists-p nil) > returns "~/dradams/" and I can't understand where the additional > slash comes from. Windows doesn't support ~FOO specifications, because there's no practical way of getting at the home directory of another user. See expand-file-name ('getpwnam' on w32.c returns NULL for any user name but the current user's). This explains ~/, but where "dradams" comes back after that is probably explained by what the completion code does, being confused by the above. From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 30 14:52:53 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 19:52:53 +0000 Received: from localhost ([127.0.0.1]:47449 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeWdo-0005mD-AN for submit@debbugs.gnu.org; Fri, 30 Nov 2012 14:52:53 -0500 Received: from aserp1040.oracle.com ([141.146.126.69]:20035) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeWdm-0005m4-63 for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 14:52:51 -0500 Received: from acsinet22.oracle.com (acsinet22.oracle.com [141.146.126.238]) by aserp1040.oracle.com (Sentrion-MTA-4.2.2/Sentrion-MTA-4.2.2) with ESMTP id qAUJof6s024547 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 30 Nov 2012 19:50:42 GMT Received: from acsmt356.oracle.com (acsmt356.oracle.com [141.146.40.156]) by acsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id qAUJof8Z011431 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 30 Nov 2012 19:50:41 GMT Received: from abhmt118.oracle.com (abhmt118.oracle.com [141.146.116.70]) by acsmt356.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id qAUJofqh021560; Fri, 30 Nov 2012 13:50:41 -0600 Received: from dradamslap1 (/10.159.169.89) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Fri, 30 Nov 2012 11:50:40 -0800 From: "Drew Adams" To: "'Stefan Monnier'" References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> <409B80A02CEB4F14B201BE9F3D5EE93C@us.oracle.com> Subject: RE: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong Date: Fri, 30 Nov 2012 11:50:36 -0800 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 In-Reply-To: Thread-Index: Ac3PKsvllPmYOx6xSyys5atGe2MsWgABzxhg X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-Source-IP: acsinet22.oracle.com [141.146.126.238] X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13033 Cc: 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) > Are you really sure that > (read-file-name-internal "~" 'file-exists-p nil) returns > "~/dradams/" even though > (completion--file-name-table "~" 'file-exists-p nil) > returns "~dradams/" No, sorry; my bad. They both return "~dradams/". > > And there is no such directory ~dradams either. > > Actually, there should be (in the same sense that there is a directory > named ~, i.e. it's a shorthand expanded by Emacs, more specifically by > `expand-file-name'). > What does C-x C-f ~dradams/.emacs RET do? It should open > your ~/.emacs file. It does. Now. But it does not in older releases. Is this change documented for Emacs on MS Windows? Is it even documented (for Emacs) for other platforms? Emacs' handling of `~' is documented, but `~' followed by `user-login-name'? Well, searching, I do see something about it in (emacs) `Minibuffer File'. And surprisingly, that text is also there in Emacs 23, even though this behavior seems new - it is not even in 24.2 (for Windows). And I see nothing about it in NEWS, but perhaps I'm not looking in the right places. This is a user-visible change, AFAICT, so it should be called out in the (Emacs 23) NEWS, I would think. > > I do not see why user-name completion (whatever that might mean for > > Unix/GNU/Linux file-name completion) is involved at all on > > Windows. The user login name has nothing to do with the user's home > > directory. > > `expand-file-name's docstring says: > > An initial `~USER/' expands to USER's home directory. That's OK for an Emacs convention. I just was not aware of it. (And for MS Windows itself there is still no association between HOME and the user login name, AFAIK. This is an Emacs-only convention. Nothing wrong with that, obviously.) From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 30 15:09:54 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 20:09:54 +0000 Received: from localhost ([127.0.0.1]:47454 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeWuI-0006An-Bu for submit@debbugs.gnu.org; Fri, 30 Nov 2012 15:09:54 -0500 Received: from mtaout22.012.net.il ([80.179.55.172]:36090) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeWuF-0006Ae-Pe for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 15:09:52 -0500 Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0MEB00M00H3RRP00@a-mtaout22.012.net.il> for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 22:07:43 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MEB00MDTH8UQD30@a-mtaout22.012.net.il>; Fri, 30 Nov 2012 22:07:43 +0200 (IST) Date: Fri, 30 Nov 2012 22:07:29 +0200 From: Eli Zaretskii Subject: Re: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong In-reply-to: X-012-Sender: halo1@inter.net.il To: Drew Adams Message-id: <83mwxyua66.fsf@gnu.org> References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> <409B80A02CEB4F14B201BE9F3D5EE93C@us.oracle.com> X-Spam-Score: 1.5 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > From: "Drew Adams" > Date: Fri, 30 Nov 2012 11:50:36 -0800 > Cc: 13033@debbugs.gnu.org > > > What does C-x C-f ~dradams/.emacs RET do? It should open > > your ~/.emacs file. > > It does. Now. But it does not in older releases. [...] Content analysis details: (1.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [80.179.55.172 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.5000] X-Debbugs-Envelope-To: 13033 Cc: monnier@iro.umontreal.ca, 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 1.5 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > From: "Drew Adams" > Date: Fri, 30 Nov 2012 11:50:36 -0800 > Cc: 13033@debbugs.gnu.org > > > What does C-x C-f ~dradams/.emacs RET do? It should open > > your ~/.emacs file. > > It does. Now. But it does not in older releases. [...] Content analysis details: (1.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [80.179.55.172 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.4848] > From: "Drew Adams" > Date: Fri, 30 Nov 2012 11:50:36 -0800 > Cc: 13033@debbugs.gnu.org > > > What does C-x C-f ~dradams/.emacs RET do? It should open > > your ~/.emacs file. > > It does. Now. But it does not in older releases. Which older releases? ~username/.emacs works for me on Windows in all releases since 21.4. > surprisingly, that text is also there in Emacs 23, even though this behavior > seems new - it is not even in 24.2 (for Windows). What happens in Emacs 24.2 for you? Are you talking about C-x C-f ~dradams/.emacs RET or about (read-file-name-internal "~" 'file-exists-p nil) ? > > An initial `~USER/' expands to USER's home directory. > > That's OK for an Emacs convention. I just was not aware of it. (And for MS > Windows itself there is still no association between HOME and the user login > name, AFAIK. Emacs on Windows supports ~USER only when USER is the current user. This support always worked in Emacs on Windows. ~USER for any other username doesn't work on Windows, and never did. (HOME is not recognized by MS-Windows itself, but HOMEDRIVE and HOMEPATH are, and they change for each user as you'd expect.) From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 30 15:11:07 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 20:11:07 +0000 Received: from localhost ([127.0.0.1]:47458 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeWvS-0006Cw-Nk for submit@debbugs.gnu.org; Fri, 30 Nov 2012 15:11:07 -0500 Received: from relais.videotron.ca ([24.201.245.36]:57890) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeWvR-0006Cp-Em for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 15:11:05 -0500 MIME-version: 1.0 Content-transfer-encoding: 7BIT Content-type: text/plain; CHARSET=US-ASCII Received: from ceviche.home ([24.201.208.110]) by VL-VM-MR001.ip.videotron.ca (Oracle Communications Messaging Exchange Server 7u4-22.01 64bit (built Apr 21 2011)) with ESMTP id <0MEB0091ZHAYM950@VL-VM-MR001.ip.videotron.ca> for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 15:08:58 -0500 (EST) Received: by ceviche.home (Postfix, from userid 20848) id 59EF066109; Fri, 30 Nov 2012 15:08:57 -0500 (EST) From: Stefan Monnier To: Drew Adams Subject: Re: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong Message-id: References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> <409B80A02CEB4F14B201BE9F3D5EE93C@us.oracle.com> Date: Fri, 30 Nov 2012 15:08:57 -0500 In-reply-to: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) X-Spam-Score: 1.6 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: >> Are you really sure that >> (read-file-name-internal "~" 'file-exists-p nil) returns >> "~/dradams/" even though >> (completion--file-name-table "~" 'file-exists-p nil) >> returns "~dradams/" > No, sorry; my bad. They both return "~dradams/". [...] Content analysis details: (1.6 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [24.201.245.36 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.5000] 0.1 HDRS_LCASE Odd capitalization of message header 0.0 T_MANY_HDRS_LCASE Odd capitalization of multiple message headers X-Debbugs-Envelope-To: 13033 Cc: 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 1.5 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: >> Are you really sure that >> (read-file-name-internal "~" 'file-exists-p nil) returns >> "~/dradams/" even though >> (completion--file-name-table "~" 'file-exists-p nil) >> returns "~dradams/" > No, sorry; my bad. They both return "~dradams/". [...] Content analysis details: (1.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [24.201.245.36 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.4997] >> Are you really sure that >> (read-file-name-internal "~" 'file-exists-p nil) returns >> "~/dradams/" even though >> (completion--file-name-table "~" 'file-exists-p nil) >> returns "~dradams/" > No, sorry; my bad. They both return "~dradams/". OK, thanks, that makes a lot more sense. So, that looks correct (i.e. not a bug). So, were you simply surprised at this behavior, or did it actually lead to an actual problem somewhere? >> > And there is no such directory ~dradams either. >> Actually, there should be (in the same sense that there is a directory >> named ~, i.e. it's a shorthand expanded by Emacs, more specifically by >> `expand-file-name'). >> What does C-x C-f ~dradams/.emacs RET do? It should open >> your ~/.emacs file. > It does. Now. But it does not in older releases. It's done so under posix "for ever". > That's OK for an Emacs convention. I just was not aware of it. (And for MS > Windows itself there is still no association between HOME and the user login > name, AFAIK. This is an Emacs-only convention. Nothing wrong with that, > obviously.) Right, I'll let Windows users figure out whether it's useful or not. Stefan From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 30 15:44:39 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 20:44:39 +0000 Received: from localhost ([127.0.0.1]:47497 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeXRv-000706-E2 for submit@debbugs.gnu.org; Fri, 30 Nov 2012 15:44:39 -0500 Received: from mtaout22.012.net.il ([80.179.55.172]:42738) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeXRs-0006zy-J2 for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 15:44:37 -0500 Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0MEB00M00HXTWS00@a-mtaout22.012.net.il> for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 22:42:28 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MEB00MUSIURQDB0@a-mtaout22.012.net.il>; Fri, 30 Nov 2012 22:42:28 +0200 (IST) Date: Fri, 30 Nov 2012 22:42:14 +0200 From: Eli Zaretskii Subject: Re: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong In-reply-to: X-012-Sender: halo1@inter.net.il To: Stefan Monnier Message-id: <83k3t2u8k9.fsf@gnu.org> References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> <409B80A02CEB4F14B201BE9F3D5EE93C@us.oracle.com> X-Spam-Score: 1.5 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > From: Stefan Monnier > Date: Fri, 30 Nov 2012 15:08:57 -0500 > Cc: 13033@debbugs.gnu.org > > >> > And there is no such directory ~dradams either. > >> Actually, there should be (in the same sense that there is a directory > >> named ~, i.e. it's a shorthand expanded by Emacs, more specifically by > >> `expand-file-name'). > >> What does C-x C-f ~dradams/.emacs RET do? It should open > >> your ~/.emacs file. > > It does. Now. But it does not in older releases. > > It's done so under posix "for ever". [...] Content analysis details: (1.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [80.179.55.172 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.4993] X-Debbugs-Envelope-To: 13033 Cc: 13033@debbugs.gnu.org, drew.adams@oracle.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 0.7 (/) > From: Stefan Monnier > Date: Fri, 30 Nov 2012 15:08:57 -0500 > Cc: 13033@debbugs.gnu.org > > >> > And there is no such directory ~dradams either. > >> Actually, there should be (in the same sense that there is a directory > >> named ~, i.e. it's a shorthand expanded by Emacs, more specifically by > >> `expand-file-name'). > >> What does C-x C-f ~dradams/.emacs RET do? It should open > >> your ~/.emacs file. > > It does. Now. But it does not in older releases. > > It's done so under posix "for ever". And it's done so on Windows forever as well. > > That's OK for an Emacs convention. I just was not aware of it. (And for MS > > Windows itself there is still no association between HOME and the user login > > name, AFAIK. This is an Emacs-only convention. Nothing wrong with that, > > obviously.) > > Right, I'll let Windows users figure out whether it's useful or not. They (Windows users) already did. From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 30 16:11:43 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 21:11:43 +0000 Received: from localhost ([127.0.0.1]:47511 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeXs7-0007cj-GS for submit@debbugs.gnu.org; Fri, 30 Nov 2012 16:11:43 -0500 Received: from aserp1040.oracle.com ([141.146.126.69]:43515) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeXs5-0007cc-PR for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 16:11:42 -0500 Received: from ucsinet22.oracle.com (ucsinet22.oracle.com [156.151.31.94]) by aserp1040.oracle.com (Sentrion-MTA-4.2.2/Sentrion-MTA-4.2.2) with ESMTP id qAUL9WPJ006096 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 30 Nov 2012 21:09:33 GMT Received: from acsmt356.oracle.com (acsmt356.oracle.com [141.146.40.156]) by ucsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id qAUL9Vik004555 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 30 Nov 2012 21:09:31 GMT Received: from abhmt108.oracle.com (abhmt108.oracle.com [141.146.116.60]) by acsmt356.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id qAUL9UjJ010717; Fri, 30 Nov 2012 15:09:31 -0600 Received: from dradamslap1 (/10.159.169.89) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Fri, 30 Nov 2012 13:09:30 -0800 From: "Drew Adams" To: "'Eli Zaretskii'" References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> <409B80A02CEB4F14B201BE9F3D5EE93C@us.oracle.com> <83mwxyua66.fsf@gnu.org> Subject: RE: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong Date: Fri, 30 Nov 2012 13:09:26 -0800 Message-ID: <0EE6D76AB45C4FF1886724E3D70E920F@us.oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <83mwxyua66.fsf@gnu.org> Thread-Index: Ac3PNl0OAo2CniQDT1Oopw6EvwOk2AABvhKw X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-Source-IP: ucsinet22.oracle.com [156.151.31.94] X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13033 Cc: monnier@iro.umontreal.ca, 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) > > > What does C-x C-f ~dradams/.emacs RET do? It should open > > > your ~/.emacs file. > > > > It does. Now. But it does not in older releases. > > Which older releases? ~username/.emacs works for me on Windows in all > releases since 21.4. I meant that what is new (what this bug report is about) is new. ;-) That is, completion of `~' to `~dradams/', or of `~dr' to `~dradams/', or `~dradams' to `~dradams/'. > What happens in Emacs 24.2 for you? Are you talking about > C-x C-f ~dradams/.emacs RET or about > (read-file-name-internal "~" 'file-exists-p nil) The latter. See above. > > > An initial `~USER/' expands to USER's home directory. > > > > That's OK for an Emacs convention. I just was not aware of > > it. (And for MS Windows itself there is still no association > > between HOME and the user login name, AFAIK. > > Emacs on Windows supports ~USER only when USER is the current user. Yes, that's what the doc says. But until now, Emacs did not support expansion of ~USER. It supported only "expansion" of ~USER/. > This support always worked in Emacs on Windows. Expansion of ~USER/, yes; of ~USER, no. From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 30 16:16:25 2012 Received: (at 13033) by debbugs.gnu.org; 30 Nov 2012 21:16:25 +0000 Received: from localhost ([127.0.0.1]:47515 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeXwf-0007ja-2e for submit@debbugs.gnu.org; Fri, 30 Nov 2012 16:16:25 -0500 Received: from userp1040.oracle.com ([156.151.31.81]:36401) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeXwc-0007jS-SL for 13033@debbugs.gnu.org; Fri, 30 Nov 2012 16:16:23 -0500 Received: from ucsinet22.oracle.com (ucsinet22.oracle.com [156.151.31.94]) by userp1040.oracle.com (Sentrion-MTA-4.2.2/Sentrion-MTA-4.2.2) with ESMTP id qAULEENn013121 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 30 Nov 2012 21:14:14 GMT Received: from acsmt356.oracle.com (acsmt356.oracle.com [141.146.40.156]) by ucsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id qAULEDhb011518 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 30 Nov 2012 21:14:13 GMT Received: from abhmt108.oracle.com (abhmt108.oracle.com [141.146.116.60]) by acsmt356.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id qAULECF5013783; Fri, 30 Nov 2012 15:14:12 -0600 Received: from dradamslap1 (/10.159.169.89) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Fri, 30 Nov 2012 13:14:12 -0800 From: "Drew Adams" To: "'Stefan Monnier'" References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> <409B80A02CEB4F14B201BE9F3D5EE93C@us.oracle.com> Subject: RE: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong Date: Fri, 30 Nov 2012 13:14:08 -0800 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 In-Reply-To: Thread-Index: Ac3PNoiQSoUxgBk/TMCHaMZDgisNkwACQSXA X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-Source-IP: ucsinet22.oracle.com [156.151.31.94] X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13033 Cc: 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) > OK, thanks, that makes a lot more sense. So, that looks correct > (i.e. not a bug). So, were you simply surprised at this behavior, or > did it actually lead to an actual problem somewhere? Surprised, I guess. From debbugs-submit-bounces@debbugs.gnu.org Sat Dec 01 02:48:58 2012 Received: (at 13033) by debbugs.gnu.org; 1 Dec 2012 07:48:58 +0000 Received: from localhost ([127.0.0.1]:47894 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tehon-00012S-Pw for submit@debbugs.gnu.org; Sat, 01 Dec 2012 02:48:58 -0500 Received: from mtaout20.012.net.il ([80.179.55.166]:38981) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tehoj-00012I-9j for 13033@debbugs.gnu.org; Sat, 01 Dec 2012 02:48:54 -0500 Received: from conversion-daemon.a-mtaout20.012.net.il by a-mtaout20.012.net.il (HyperSendmail v2007.08) id <0MEC00400DH27200@a-mtaout20.012.net.il> for 13033@debbugs.gnu.org; Sat, 01 Dec 2012 09:46:41 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout20.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MEC003I8DLTKSA0@a-mtaout20.012.net.il>; Sat, 01 Dec 2012 09:46:41 +0200 (IST) Date: Sat, 01 Dec 2012 09:46:29 +0200 From: Eli Zaretskii Subject: Re: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong In-reply-to: <0EE6D76AB45C4FF1886724E3D70E920F@us.oracle.com> X-012-Sender: halo1@inter.net.il To: Drew Adams Message-id: <83ip8mtdt6.fsf@gnu.org> References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> <409B80A02CEB4F14B201BE9F3D5EE93C@us.oracle.com> <83mwxyua66.fsf@gnu.org> <0EE6D76AB45C4FF1886724E3D70E920F@us.oracle.com> X-Spam-Score: 1.5 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > From: "Drew Adams" > Cc: , <13033@debbugs.gnu.org> > Date: Fri, 30 Nov 2012 13:09:26 -0800 > > > Emacs on Windows supports ~USER only when USER is the current user. > > Yes, that's what the doc says. But until now, Emacs did not support expansion > of ~USER. It supported only "expansion" of ~USER/. [...] Content analysis details: (1.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [80.179.55.166 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.4669] X-Debbugs-Envelope-To: 13033 Cc: monnier@iro.umontreal.ca, 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 0.7 (/) > From: "Drew Adams" > Cc: , <13033@debbugs.gnu.org> > Date: Fri, 30 Nov 2012 13:09:26 -0800 > > > Emacs on Windows supports ~USER only when USER is the current user. > > Yes, that's what the doc says. But until now, Emacs did not support expansion > of ~USER. It supported only "expansion" of ~USER/. You mean, 'M-: (expand-file-name "~dradams") RET' doesn't work for you in any previous releases? It does for me (with my username instead of dradams) at least since 21.4. It expands to my home directory. If that is not what you mean, then what "expansion" are you talking about? From debbugs-submit-bounces@debbugs.gnu.org Sat Dec 01 05:14:35 2012 Received: (at 13033) by debbugs.gnu.org; 1 Dec 2012 10:14:35 +0000 Received: from localhost ([127.0.0.1]:47955 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tek5i-0004Mg-PI for submit@debbugs.gnu.org; Sat, 01 Dec 2012 05:14:35 -0500 Received: from mout.web.de ([212.227.15.3]:62975) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tek5g-0004MW-1U for 13033@debbugs.gnu.org; Sat, 01 Dec 2012 05:14:33 -0500 Received: from drachen.dragon ([89.204.138.49]) by smtp.web.de (mrweb003) with ESMTPA (Nemesis) id 0LqDTc-1T0zSd1ILw-00e8B1; Sat, 01 Dec 2012 11:12:20 +0100 From: Michael Heerdegen To: Eli Zaretskii Subject: Re: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> <87d2yvute9.fsf@web.de> <8338zrurdq.fsf@gnu.org> Date: Sat, 01 Dec 2012 11:13:04 +0100 In-Reply-To: <8338zrurdq.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 30 Nov 2012 15:55:45 +0200") Message-ID: <87k3t2w05r.fsf@web.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.90 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V02:K0:YnSOs3jvhq+7syfR23u9MzitPlmO2BiE2qy7O+tQAKi wIHBzQFaY0RDoojX4Wj9xAbLeH7y5VNencIDqvyj0GqIJg9kSw y4JtKUheHfq7okIBX2eJHK22l4/Pd0+OdB20/5zi8N3aMQk9Mq 6Us/CWaMWSPo4BYDElVoPhSXWg6LO4HFlba1+MwX18rnyCvp6x kvKshrZXMC2M242k/oYk4FPRx5Fb0nLn10okR0iD0E= X-Spam-Score: 0.4 (/) X-Debbugs-Envelope-To: 13033 Cc: lekktu@gmail.com, 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 0.4 (/) Eli Zaretskii writes: > > It is a bug if something like `read-file-name-internal' is not > > allowed to be called in third-party packages. > > Then please submit bug reports, asking for features that you cannot > get from other APIs. Ok, I'll remember that. But I wouldn't be surprised if the new API would just be a corrected and documented version of `read-file-name-internal'. > > At university I learned that writing software happens in a way that > > every function should have a clear specification for what it > > does/returns, and a documentation of this. > > If they didn't teach you about the difference between internal APIs > and public APIs, then it's too bad. Yeah, education here is quite strange and idealistic. They even told us that such specification and documentation would help developers understanding the code, as well as it would help these people that maybe want to change this code some years later. > Nevertheless, the distinction is part of our lives. Some languages > have means to conceal private APIs from external applications, but C > and Emacs Lisp don't. So we use whatever we got; please always assume > that there are good reasons for that. (It is OK, of course, to > question those reasons, but ignoring them is not wise, IMO.) You're right, I think I question the reasons, in this case. So, I don't think we disagree here. IIUC, what we need for Icicles is a completion table for filename completion that can be used as the COLLECTION argument for `try-completion' or `all-completions'. That is, I guess, something like a not forbidden version of `read-file-name-internal'. Michael. From debbugs-submit-bounces@debbugs.gnu.org Sat Dec 01 11:36:53 2012 Received: (at 13033) by debbugs.gnu.org; 1 Dec 2012 16:36:53 +0000 Received: from localhost ([127.0.0.1]:48704 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Teq3h-0005lX-BO for submit@debbugs.gnu.org; Sat, 01 Dec 2012 11:36:53 -0500 Received: from userp1040.oracle.com ([156.151.31.81]:36208) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Teq3e-0005lP-HD for 13033@debbugs.gnu.org; Sat, 01 Dec 2012 11:36:51 -0500 Received: from ucsinet22.oracle.com (ucsinet22.oracle.com [156.151.31.94]) by userp1040.oracle.com (Sentrion-MTA-4.2.2/Sentrion-MTA-4.2.2) with ESMTP id qB1GYaQj009514 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Sat, 1 Dec 2012 16:34:37 GMT Received: from acsmt357.oracle.com (acsmt357.oracle.com [141.146.40.157]) by ucsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id qB1GYZS5013551 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 1 Dec 2012 16:34:36 GMT Received: from abhmt119.oracle.com (abhmt119.oracle.com [141.146.116.71]) by acsmt357.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id qB1GYZM0001107; Sat, 1 Dec 2012 10:34:35 -0600 Received: from dradamslap1 (/71.202.147.44) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Sat, 01 Dec 2012 08:34:35 -0800 From: "Drew Adams" To: "'Eli Zaretskii'" References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> <409B80A02CEB4F14B201BE9F3D5EE93C@us.oracle.com> <83mwxyua66.fsf@gnu.org> <0EE6D76AB45C4FF1886724E3D70E920F@us.oracle.com> <83ip8mtdt6.fsf@gnu.org> Subject: RE: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong Date: Sat, 1 Dec 2012 08:34:28 -0800 Message-ID: <66BA6F2DC0D54C7E962EC2F82CA84A7E@us.oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <83ip8mtdt6.fsf@gnu.org> Thread-Index: Ac3PmAKlO79rhYfmQIGuMAa/EVcKfAARVLew X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-Source-IP: ucsinet22.oracle.com [156.151.31.94] X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 13033 Cc: monnier@iro.umontreal.ca, 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) > > > Emacs on Windows supports ~USER only when USER is the > > > current user. > > > > Yes, that's what the doc says. But until now, Emacs did > > not support expansion of ~USER. It supported only "expansion" > > of ~USER/. > > You mean, 'M-: (expand-file-name "~dradams") RET' doesn't work for you > in any previous releases? It does for me (with my username instead of > dradams) at least since 21.4. It expands to my home directory. > > If that is not what you mean, then what "expansion" are you talking > about? I thought I made clear that I was talking about completion. I used quotation marks around "expansion" to emphasize that. What is new is the completion behavior. From debbugs-submit-bounces@debbugs.gnu.org Sat Feb 08 21:53:11 2014 Received: (at 13033) by debbugs.gnu.org; 9 Feb 2014 02:53:11 +0000 Received: from localhost ([127.0.0.1]:58574 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WCKW7-0000AH-F0 for submit@debbugs.gnu.org; Sat, 08 Feb 2014 21:53:11 -0500 Received: from hermes.netfonds.no ([80.91.224.195]:53980) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WCKW5-00009x-3O for 13033@debbugs.gnu.org; Sat, 08 Feb 2014 21:53:10 -0500 Received: from [204.14.154.233] (helo=building.gnus.org) by hermes.netfonds.no with esmtpsa (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1WCKVm-00047M-SG; Sun, 09 Feb 2014 03:52:51 +0100 From: Lars Ingebrigtsen To: "Drew Adams" Subject: Re: bug#13033: 24.3.50; regression: read-file-name-internal handles "~" wrong References: <7FC6A56C048B4EEAAE8EF71367793001@us.oracle.com> <409B80A02CEB4F14B201BE9F3D5EE93C@us.oracle.com> Date: Sat, 08 Feb 2014 18:51:38 -0800 In-Reply-To: (Drew Adams's message of "Fri, 30 Nov 2012 13:14:08 -0800") Message-ID: <87lhxlj8w5.fsf@building.gnus.org> User-Agent: Gnus/5.13001 (Ma Gnus v0.10) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-MailScanner-ID: 1WCKVm-00047M-SG X-Netfonds-MailScanner: Found to be clean X-Netfonds-MailScanner-From: larsi@gnus.org MailScanner-NULL-Check: 1392519174.89947@iKbI2sO/ffzVMwGrs9+1Bg X-Spam-Status: No X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 13033 Cc: 'Stefan Monnier' , 13033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.0 (/) "Drew Adams" writes: >> OK, thanks, that makes a lot more sense. So, that looks correct >> (i.e. not a bug). So, were you simply surprised at this behavior, or >> did it actually lead to an actual problem somewhere? > > Surprised, I guess. So this doesn't seem to be a bug. Closing. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog http://lars.ingebrigtsen.no/ From debbugs-submit-bounces@debbugs.gnu.org Sat Feb 08 21:53:12 2014 Received: (at control) by debbugs.gnu.org; 9 Feb 2014 02:53:12 +0000 Received: from localhost ([127.0.0.1]:58576 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WCKW7-0000AJ-PX for submit@debbugs.gnu.org; Sat, 08 Feb 2014 21:53:11 -0500 Received: from hermes.netfonds.no ([80.91.224.195]:53985) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WCKW6-00009z-2K for control@debbugs.gnu.org; Sat, 08 Feb 2014 21:53:10 -0500 Received: from [204.14.154.233] (helo=building.gnus.org) by hermes.netfonds.no with esmtpsa (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1WCKVr-00047U-UG for control@debbugs.gnu.org; Sun, 09 Feb 2014 03:52:56 +0100 Date: Sat, 08 Feb 2014 18:51:45 -0800 Message-Id: <87k3d5j8vy.fsf@building.gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #13033 X-MailScanner-ID: 1WCKVr-00047U-UG X-Netfonds-MailScanner: Found to be clean X-Netfonds-MailScanner-From: larsi@gnus.org MailScanner-NULL-Check: 1392519176.57539@2mYSdpZoEo0nCqNU46V+cg X-Spam-Status: No X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.0 (/) close 13033 From unknown Sun Jun 22 00:00:23 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sun, 09 Mar 2014 11:24:05 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator