summaryrefslogtreecommitdiff
path: root/Master/tlpkg/tlperl/lib/TAP/Object.pm
diff options
context:
space:
mode:
Diffstat (limited to 'Master/tlpkg/tlperl/lib/TAP/Object.pm')
-rw-r--r--Master/tlpkg/tlperl/lib/TAP/Object.pm25
1 files changed, 22 insertions, 3 deletions
diff --git a/Master/tlpkg/tlperl/lib/TAP/Object.pm b/Master/tlpkg/tlperl/lib/TAP/Object.pm
index 498bb805c91..e933179c916 100644
--- a/Master/tlpkg/tlperl/lib/TAP/Object.pm
+++ b/Master/tlpkg/tlperl/lib/TAP/Object.pm
@@ -9,11 +9,11 @@ TAP::Object - Base class that provides common functionality to all C<TAP::*> mod
=head1 VERSION
-Version 3.17
+Version 3.23
=cut
-$VERSION = '3.17';
+$VERSION = '3.23';
=head1 SYNOPSIS
@@ -93,6 +93,25 @@ sub _croak {
return;
}
+=head3 C<_confess>
+
+Raise an exception using C<confess> from L<Carp>, eg:
+
+ $self->_confess( 'why me?', 'aaarrgh!' );
+
+May also be called as a I<class> method.
+
+ $class->_confess( 'this works too' );
+
+=cut
+
+sub _confess {
+ my $proto = shift;
+ require Carp;
+ Carp::confess(@_);
+ return;
+}
+
=head3 C<_construct>
Create a new instance of the specified class.
@@ -124,7 +143,7 @@ Create simple getter/setters.
sub mk_methods {
my ( $class, @methods ) = @_;
- foreach my $method_name (@methods) {
+ for my $method_name (@methods) {
my $method = "${class}::$method_name";
no strict 'refs';
*$method = sub {