From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: poffice@blade.nagaokaut.ac.jp Delivered-To: poffice@blade.nagaokaut.ac.jp Received: from kankan.nagaokaut.ac.jp (kankan.nagaokaut.ac.jp [133.44.2.24]) by blade.nagaokaut.ac.jp (Postfix) with ESMTP id A205B17DF75A for ; Sun, 3 May 2015 19:22:54 +0900 (JST) Received: from funfun.nagaokaut.ac.jp (funfun.nagaokaut.ac.jp [133.44.2.201]) by kankan.nagaokaut.ac.jp (Postfix) with ESMTP id EBDEBB5D8DB for ; Sun, 3 May 2015 19:36:43 +0900 (JST) Received: from funfun.nagaokaut.ac.jp (localhost.nagaokaut.ac.jp [127.0.0.1]) by funfun.nagaokaut.ac.jp (Postfix) with ESMTP id 3D5BB97A826 for ; Sun, 3 May 2015 19:36:46 +0900 (JST) X-Virus-Scanned: amavisd-new at nagaokaut.ac.jp Authentication-Results: funfun.nagaokaut.ac.jp (amavisd-new); dkim=fail (1024-bit key) reason="fail (message has been altered)" header.d=sendgrid.me Received: from funfun.nagaokaut.ac.jp ([127.0.0.1]) by funfun.nagaokaut.ac.jp (funfun.nagaokaut.ac.jp [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id wW72L27Nxk_K for ; Sun, 3 May 2015 19:36:45 +0900 (JST) Received: from voscc.nagaokaut.ac.jp (voscc.nagaokaut.ac.jp [133.44.1.100]) by funfun.nagaokaut.ac.jp (Postfix) with ESMTP id BC46797A820 for ; Sun, 3 May 2015 19:36:45 +0900 (JST) Received: from neon.ruby-lang.org (neon.ruby-lang.org [221.186.184.75]) by voscc.nagaokaut.ac.jp (Postfix) with ESMTP id 6FE05952439 for ; Sun, 3 May 2015 19:36:43 +0900 (JST) Received: from [221.186.184.76] (localhost [IPv6:::1]) by neon.ruby-lang.org (Postfix) with ESMTP id EBB1312045E; Sun, 3 May 2015 19:36:41 +0900 (JST) X-Original-To: ruby-core@ruby-lang.org Delivered-To: ruby-core@ruby-lang.org Received: from o10.shared.sendgrid.net (o10.shared.sendgrid.net [173.193.132.135]) by neon.ruby-lang.org (Postfix) with ESMTPS id 87303120440 for ; Sun, 3 May 2015 19:36:38 +0900 (JST) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sendgrid.me; h=from:to:references:subject:mime-version:content-type:content-transfer-encoding:list-id; s=smtpapi; bh=ctg0j5itwbekSLdNJLQ5DsWEKIo=; b=sTFOrf11de/KV5ypC8 /EPbcRM+aGZDptHIFNlQPsHcdvU0tZcLlCVXMQHErXql2qwUzjxdtT/bbDpbUCPH x248UZEQsxo7EAI9xk1G18J5ykRqDk0b1zukke7BF5ZpYwGXkqaCC8mbyXUVAMkd VthyXQSHsL0tncddyCSJDT84w= Received: by filter0492p1mdw1.sendgrid.net with SMTP id filter0492p1mdw1.19294.5545FA31C 2015-05-03 10:36:33.906434451 +0000 UTC Received: from herokuapp.com (ec2-174-129-156-14.compute-1.amazonaws.com [174.129.156.14]) by ismtpd-042 (SG) with ESMTP id 14d195952ba.6924.1d9ba8 for ; Sun, 03 May 2015 10:36:33 +0000 (UTC) Date: Sun, 03 May 2015 10:36:33 +0000 From: mame@ruby-lang.org To: ruby-core@ruby-lang.org Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Redmine-MailingListIntegration-Message-Ids: 43466 X-Redmine-Project: ruby-trunk X-Redmine-Issue-Id: 11116 X-Redmine-Issue-Author: mame X-Redmine-Issue-Assignee: mame X-Redmine-Sender: mame 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: ync6xU2WACa70kv/Ymy4QrNMhiuLXJG8OTL2vJD1yS5KHoOm0XMd/kn989w5Kz7Feny0Ve3seaQ6sP oHcxJE510OP/hpp00XUblV16vqoKG7cs9eh+CI1IJJRHKQr00K+IRU8XRK/WBJvdPLPMFWvTaKHdmc XbROkyxXXGQvwJjxKO0oZr0Pig01yJMymdM1 X-ML-Name: ruby-core X-Mail-Count: 69063 Subject: [ruby-core:69063] [Ruby trunk - Bug #11116] [Open] The spec of String#dump 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: , Errors-To: ruby-core-bounces@ruby-lang.org Sender: "ruby-core" Issue #11116 has been reported by Yusuke Endoh. ---------------------------------------- Bug #11116: The spec of String#dump https://bugs.ruby-lang.org/issues/11116 * Author: Yusuke Endoh * Status: Open * Priority: Normal * Assignee: Yusuke Endoh * ruby -v: ruby 2.2.1p85 (2015-02-26 revision 49769) [x86_64-linux] * Backport: 2.0.0: UNKNOWN, 2.1: UNKNOWN, 2.2: UNKNOWN ---------------------------------------- The current spec says: call-seq: str.dump -> new_str Produces a version of +str+ with all non-printing characters replaced by \nnn notation and all special characters escaped. "hello \n ''".dump #=> "\"hello \\n ''\" `\nnn` must be `\xnn` now. In addition, I've expected String#dump to return a string that evaluates to an original string (except singleton methods, object id, etc.) when `eval`ed. Is this a right expectation? If so, it would be good to officially include the mention in the spec. What do you think? -- Yusuke Endoh -- https://bugs.ruby-lang.org/