Skip to content

Commit

Permalink
Add X::NYI.workaround
Browse files Browse the repository at this point in the history
So we can give workaround information if necessary
  • Loading branch information
lizmat committed Nov 2, 2017
1 parent c2baf95 commit 9f54bc9
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/core/Exception.pm
Expand Up @@ -780,9 +780,11 @@ my role X::Pod { }
my class X::NYI is Exception {
has $.feature;
has $.did-you-mean;
has $.workaround;
method message() {
my $msg = "$.feature not yet implemented. Sorry.";
$msg ~= "\nDid you mean: {$.did-you-mean.gist}?" if $.did-you-mean;
$msg ~= "\nWorkaround: $.workaround" if $.workaround;
$msg
}
}
Expand Down

0 comments on commit 9f54bc9

Please sign in to comment.