[Bast-commits] r4341 - trunk/Devel-REPL/lib/Devel/REPL

nothingmuch at dev.catalyst.perl.org nothingmuch at dev.catalyst.perl.org
Tue May 6 08:49:51 BST 2008


Author: nothingmuch
Date: 2008-05-06 08:49:51 +0100 (Tue, 06 May 2008)
New Revision: 4341

Added:
   trunk/Devel-REPL/lib/Devel/REPL/Error.pm
Log:
Devel::REPL::Error

Added: trunk/Devel-REPL/lib/Devel/REPL/Error.pm
===================================================================
--- trunk/Devel-REPL/lib/Devel/REPL/Error.pm	                        (rev 0)
+++ trunk/Devel-REPL/lib/Devel/REPL/Error.pm	2008-05-06 07:49:51 UTC (rev 4341)
@@ -0,0 +1,27 @@
+#!/usr/bin/perl
+
+package Devel::REPL::Error;
+use Moose;
+
+# FIXME get nothingmuch to refactor and release his useful error object
+
+has type => (
+  isa => "Str",
+  is  => "ro",
+  required => 1,
+);
+
+has message => (
+  isa => "Str",
+  is  => "ro",
+  required => 1,
+);
+
+sub stringify {
+  my $self = shift;
+
+  sprintf "%s: %s", $self->type, $self->message;
+}
+__PACKAGE__
+
+__END__




More information about the Bast-commits mailing list