Skip to content

Instantly share code, notes, and snippets.

@Ovid
Created February 18, 2012 10:18
Show Gist options
  • Save Ovid/1858605 to your computer and use it in GitHub Desktop.
Save Ovid/1858605 to your computer and use it in GitHub Desktop.
Strange syntax error when asserting version
use strict;
use warnings;
use Devel::Peek;
Dump $_ for .96, 0.96;
# this is fine
eval "use Data::Dumper 0.01 'Dumper'";
my $error = $@ || "none";
print "\nError is: $error\n";
print "---------------------------\n";
# this is a syntax error
eval "use Data::Dumper .01 'Dumper'";
$error = $@ || "none";
print "\nError is: $error\n";
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment