From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=AWL,BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS,UNPARSEABLE_RELAY shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from neon.ruby-lang.org (neon.ruby-lang.org [221.186.184.75]) by dcvr.yhbt.net (Postfix) with ESMTP id A8C6C1F4B4 for ; Thu, 7 Jan 2021 04:39:14 +0000 (UTC) Received: from neon.ruby-lang.org (localhost [IPv6:::1]) by neon.ruby-lang.org (Postfix) with ESMTP id 21EC01209F6; Thu, 7 Jan 2021 13:38:23 +0900 (JST) Received: from xtrwkhkc.outbound-mail.sendgrid.net (xtrwkhkc.outbound-mail.sendgrid.net [167.89.16.28]) by neon.ruby-lang.org (Postfix) with ESMTPS id 756C01209F5 for ; Thu, 7 Jan 2021 13:38:21 +0900 (JST) Received: by filterdrecv-p3mdw1-7474cd8bfd-9jk94 with SMTP id filterdrecv-p3mdw1-7474cd8bfd-9jk94-19-5FF6906B-1F 2021-01-07 04:39:07.65489769 +0000 UTC m=+2353021.137025261 Received: from herokuapp.com (unknown) by ismtpd0022p1iad2.sendgrid.net (SG) with ESMTP id ys1xwiWkTaaVLbqq30vEJA for ; Thu, 07 Jan 2021 04:39:07.536 +0000 (UTC) Date: Thu, 07 Jan 2021 04:39:07 +0000 (UTC) From: duerst@it.aoyama.ac.jp Message-ID: References: Mime-Version: 1.0 X-Redmine-MailingListIntegration-Message-Ids: 77875 X-Redmine-Project: ruby-master X-Redmine-Issue-Tracker: Bug X-Redmine-Issue-Id: 17517 X-Redmine-Issue-Author: znz X-Redmine-Sender: duerst X-Mailer: Redmine X-Redmine-Host: bugs.ruby-lang.org X-Redmine-Site: Ruby Issue Tracking System X-Auto-Response-Suppress: All Auto-Submitted: auto-generated X-SG-EID: =?us-ascii?Q?uQY=2F2xNrNfHHTWbKn6MBvvzfU5Pqk9I4lnOVb0CFDuuM=2FfYkInVfZ9bqpbhEFm?= =?us-ascii?Q?KBRwbHduEx94THmqK0mHBauuCegoL+7sBxwUDHD?= =?us-ascii?Q?d1wLhcTrylfzVk9s754nmd9hhIEZF8ac3fV+RVw?= =?us-ascii?Q?dmg04RqWodlrqU=2FDHsW6o4nW9JuXOUvxewZ2Tu=2F?= =?us-ascii?Q?6=2FtJW8rx4nRgAShSeq1ERfw5FpT9ku7LshA6FrK?= =?us-ascii?Q?IW4EOn671N6F8KtU0=3D?= To: ruby-core@ruby-lang.org X-Entity-ID: b/2+PoftWZ6GuOu3b0IycA== X-ML-Name: ruby-core X-Mail-Count: 101969 Subject: [ruby-core:101969] [Ruby master Bug#17517] File.expand_path returns us-ascii when both arguments are ascii compat X-BeenThere: ruby-core@ruby-lang.org X-Mailman-Version: 2.1.15 Precedence: list Reply-To: Ruby developers List-Id: Ruby developers List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Errors-To: ruby-core-bounces@ruby-lang.org Sender: "ruby-core" Issue #17517 has been updated by duerst (Martin D=FCrst). Subject changed from File.expand_path returns us-aascii when both arguments= are ascii compat to File.expand_path returns us-ascii when both arguments = are ascii compat Fix a typo in subject. ---------------------------------------- Bug #17517: File.expand_path returns us-ascii when both arguments are ascii= compat https://bugs.ruby-lang.org/issues/17517#change-89821 * Author: znz (Kazuhiro NISHIYAMA) * Status: Open * Priority: Normal * Backport: 2.5: UNKNOWN, 2.6: UNKNOWN, 2.7: UNKNOWN, 3.0: UNKNOWN ---------------------------------------- Is this intentional? ```ruby p __dir__.encoding #=3D> # p 'hoge'.encoding #=3D> # p File.expand_path('hoge', __dir__).encoding #=3D> # ``` ``` % docker run -it --rm ghcr.io/ruby/all-ruby env ALL_RUBY_SINCE=3Druby-1.9 .= /all-ruby -e 'p File.expand_path("hoge".encode("utf-8"), "/".encode("utf-8"= )).encoding' ruby-1.9.0-0 -e:1:in `encode': transcoding not supported (from ASCII= -8BIT to UTF-8) (ArgumentError) from -e:1:in `
' exit 1 ruby-1.9.0-1 # ruby-1.9.0-2 # ... ruby-1.9.1-p129 # ruby-1.9.1-p243 # ... ruby-1.9.2-preview1 # ruby-1.9.2-preview3 # ... ruby-3.0.0 # ``` -- = https://bugs.ruby-lang.org/ Unsubscribe: