# New Ticket Created by  Sam S. 
# Please include the string:  [perl #125279]
# in the subject line of all future correspondence about this issue. 
# <URL: https://rt.perl.org/Ticket/Display.html?id=125279 >



>From 0982b07b9f44df098aefa7c51948dfbb8037cae4 Mon Sep 17 00:00:00 2001
From: smls <sml...@gmail.com>
Date: Fri, 29 May 2015 19:59:41 +0200
Subject: [PATCH] Fix typo in IO::Path.rename

This cause a bogus "Cannot find method 'postcircumfix:<( )>'" exception to be 
thrown when trying to rename a nonexistent file, instead of returning the 
correct Failure.
---
 src/core/IO/Path.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/core/IO/Path.pm b/src/core/IO/Path.pm
index ace11a6..24bcc10 100644
--- a/src/core/IO/Path.pm
+++ b/src/core/IO/Path.pm
@@ -306,7 +306,7 @@ my class IO::Path is Cool {
         nqp::rename($.abspath, nqp::unbox_s($to.abspath));
         CATCH { default {
             fail X::IO::Rename.new(
-              :from($!abspath), :$to($to.abspath), :os-error(.Str) );
+              :from($!abspath), :to($to.abspath), :os-error(.Str) );
         } }
         True;
     }
-- 
2.4.1

Reply via email to