[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[SCM] Debian package checker branch, lab-refactor, updated. 2.5.3-179-gfffad83



The following commit has been merged in the lab-refactor branch:
commit fffad835d14a9c75d67e153cc3962cab5c9398ff
Author: Niels Thykier <niels@thykier.net>
Date:   Tue Nov 1 08:04:36 2011 +0100

    Improve some documentation and an error message
    
    Signed-off-by: Niels Thykier <niels@thykier.net>

diff --git a/lib/Lintian/Lab.pm b/lib/Lintian/Lab.pm
index db34abd..9fd0f1b 100644
--- a/lib/Lintian/Lab.pm
+++ b/lib/Lintian/Lab.pm
@@ -160,8 +160,8 @@ non-empty value from this method.
 
 Returns a truth value if this lab is open.
 
-XXX: What is this trying to say?
-Note: This does not imply that the underlying lab does not exist.
+Note: If the lab is open, it also exists.  However, if the lab is
+closed then the lab may or may not exists (see L</lab_exists>).
 
 =cut
 
@@ -171,7 +171,8 @@ Lintian::Lab->mk_ro_accessors (qw(dir is_open));
 
 Returns a truth value if B<$lab> points to an existing lab.
 
-Note: This does not imply whether or not the lab is open.
+Note: This never implies that the lab is open.  Though it may imply
+the lab is closed (see L</is_open>).
 
 =cut
 
diff --git a/lib/Lintian/Lab/Manifest.pm b/lib/Lintian/Lab/Manifest.pm
index f89abdf..7167adb 100644
--- a/lib/Lintian/Lab/Manifest.pm
+++ b/lib/Lintian/Lab/Manifest.pm
@@ -378,8 +378,11 @@ sub diff {
     my @added;
     my @removed;
     my $visitor;
-    # TODO: worth mentioning the types in the error?
-    croak "Diffing incompatible types" unless $self->{'type'} eq $other->{'type'};
+    unless ($self->{'type'} eq $other->{'type'}) {
+        my $st = $self->{'type'};
+        my $ot = $other->{'type'});
+        croak "Diffing incompatible types ($st != $ot)";
+    }
     $copy = $self->clone;
 
     $visitor = sub {

-- 
Debian package checker


Reply to: