Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Found a more elegant way to deal with our 'isa' problem

  • Loading branch information...
commit 8631ee6c74fc8b38f770621bc834619ba9caf975 1 parent 225c1dd
Chris Williams authored May 18, 2010
11  Changes
... ...
@@ -1,4 +1,15 @@
1 1
 ==============================
  2
+2010-05-18 09:10:40 +0100 0.06
  3
+==============================
  4
+
  5
+  commit 225c1ddde7fe4bdf568fba7784da4e4599444cf5
  6
+  Author: Chris 'BinGOs' Williams <chris@bingosnet.co.uk>
  7
+  Date:   Tue May 18 09:10:40 2010 +0100
  8
+  
  9
+    Fixed a few issues, tested patching against perl-5.6.1 source tree
  10
+    and it works now. 
  11
+
  12
+==============================
2 13
 2010-05-18 00:33:32 +0100 0.04
3 14
 ==============================
4 15
 
4  lib/Devel/PatchPerl.pm
@@ -8,7 +8,7 @@ use IO::File;
8 8
 use IPC::Cmd qw[can_run run];
9 9
 use vars qw[$VERSION @ISA @EXPORT_OK];
10 10
 
11  
-$VERSION = '0.06';
  11
+$VERSION = '0.08';
12 12
 
13 13
 @ISA       = qw(Exporter);
14 14
 @EXPORT_OK = qw(patch_source);
@@ -104,7 +104,7 @@ my @patch = (
104 104
 
105 105
 sub patch_source {
106 106
   my $vers = shift;
107  
-  $vers = shift if $vers !~ /^[\d.]+$/ and $vers->isa(__PACKAGE__);
  107
+  $vers = shift if eval { $vers->isa(__PACKAGE__) };
108 108
   my $source = shift || '.';
109 109
   $source = File::Spec->rel2abs($source);
110 110
   warn "No patch utility found\n" unless $patch_exe;

0 notes on commit 8631ee6

Please sign in to comment.
Something went wrong with that request. Please try again.