Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge pull request #30 from sergot/master
nicer error message when file specified at command line is not found; maybe not perfect, but surely an improvement from user's point of view
  • Loading branch information
jnthn committed Feb 26, 2012
2 parents d44ab2e + 3133d4a commit 9903471
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/HLL/Compiler.pm
Expand Up @@ -398,10 +398,13 @@ class HLL::Compiler {
pir::push(@codes, $in-handle.readall($_));
$in-handle.close;
CATCH {
$err := "Error while reading from file: $_";
$err := "$_\n";
}
}
pir::die($err) if $err;
if $err {
pir::printerr($err);
pir::exit(1);
}
}
my $code := pir::join('', @codes);
my $?FILES := pir::join(' ', @files);
Expand Down

0 comments on commit 9903471

Please sign in to comment.