#!/usr/bin/perl use strict; use warnings; use File::Path; my $path = q{a:/tmp}; # non existent drive eval {no warnings 'all'; mkpath $path}; if ($@){ print qq{failed\n}; } else{ print qq{ok\n}; } #### Argument "No such file or directory; The system cannot find the pa..." isn't numeric in scalar assignment at c:/perl/lib/File/Path.pm line 152. failed