r3424 - in /packages/libparams-classify-perl/trunk: .cvsignore Changes MANIFEST META.yml Makefile.PL README debian/changelog debian/compat debian/control debian/rules lib/Params/Classify.pm t/ref.t

gregoa-guest at users.alioth.debian.org gregoa-guest at users.alioth.debian.org
Mon Aug 7 15:48:37 UTC 2006


Author: gregoa-guest
Date: Mon Aug  7 15:48:34 2006
New Revision: 3424

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=3424
Log:
* New upstream release.
* Set Standards-Version to 3.7.2 (no changes).
* Set debhelper compatibility level to 5.
* Remove empty /usr/lib/perl5 directory from package.

Added:
    packages/libparams-classify-perl/trunk/Changes
      - copied unchanged from r3423, packages/libparams-classify-perl/branches/upstream/current/Changes
    packages/libparams-classify-perl/trunk/META.yml
      - copied unchanged from r3423, packages/libparams-classify-perl/branches/upstream/current/META.yml
Modified:
    packages/libparams-classify-perl/trunk/.cvsignore
    packages/libparams-classify-perl/trunk/MANIFEST
    packages/libparams-classify-perl/trunk/Makefile.PL
    packages/libparams-classify-perl/trunk/README
    packages/libparams-classify-perl/trunk/debian/changelog
    packages/libparams-classify-perl/trunk/debian/compat
    packages/libparams-classify-perl/trunk/debian/control
    packages/libparams-classify-perl/trunk/debian/rules
    packages/libparams-classify-perl/trunk/lib/Params/Classify.pm
    packages/libparams-classify-perl/trunk/t/ref.t

Modified: packages/libparams-classify-perl/trunk/.cvsignore
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libparams-classify-perl/trunk/.cvsignore?rev=3424&op=diff
==============================================================================
--- packages/libparams-classify-perl/trunk/.cvsignore (original)
+++ packages/libparams-classify-perl/trunk/.cvsignore Mon Aug  7 15:48:34 2006
@@ -1,4 +1,4 @@
 Makefile Makefile.old
 blib pm_to_blib
 META.yml
-IPC-Signal-Force-*
+Params-Classify-*

Modified: packages/libparams-classify-perl/trunk/MANIFEST
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libparams-classify-perl/trunk/MANIFEST?rev=3424&op=diff
==============================================================================
--- packages/libparams-classify-perl/trunk/MANIFEST (original)
+++ packages/libparams-classify-perl/trunk/MANIFEST Mon Aug  7 15:48:34 2006
@@ -1,4 +1,5 @@
 .cvsignore
+Changes
 MANIFEST
 META.yml
 Makefile.PL

Modified: packages/libparams-classify-perl/trunk/Makefile.PL
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libparams-classify-perl/trunk/Makefile.PL?rev=3424&op=diff
==============================================================================
--- packages/libparams-classify-perl/trunk/Makefile.PL (original)
+++ packages/libparams-classify-perl/trunk/Makefile.PL Mon Aug  7 15:48:34 2006
@@ -3,4 +3,7 @@
 WriteMakefile(
 	NAME => "Params::Classify",
 	VERSION_FROM => "lib/Params/Classify.pm",
+	PREREQ_PM => {
+		"Scalar::Util" => "1.01",
+	},
 );

Modified: packages/libparams-classify-perl/trunk/README
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libparams-classify-perl/trunk/README?rev=3424&op=diff
==============================================================================
--- packages/libparams-classify-perl/trunk/README (original)
+++ packages/libparams-classify-perl/trunk/README Mon Aug  7 15:48:34 2006
@@ -28,7 +28,7 @@
 
 COPYRIGHT
 
-Copyright (C) 2004 Andrew Main (Zefram) <zefram at fysh.org>
+Copyright (C) 2004, 2006 Andrew Main (Zefram) <zefram at fysh.org>
 
 This module is free software; you can redistribute it and/or modify it
 under the same terms as Perl itself.

Modified: packages/libparams-classify-perl/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libparams-classify-perl/trunk/debian/changelog?rev=3424&op=diff
==============================================================================
--- packages/libparams-classify-perl/trunk/debian/changelog (original)
+++ packages/libparams-classify-perl/trunk/debian/changelog Mon Aug  7 15:48:34 2006
@@ -1,3 +1,12 @@
+libparams-classify-perl (0.001-1) unstable; urgency=low
+
+  * New upstream release.
+  * Set Standards-Version to 3.7.2 (no changes).
+  * Set debhelper compatibility level to 5.
+  * Remove empty /usr/lib/perl5 directory from package.
+
+ -- gregor herrmann <gregor+debian at comodo.priv.at>  Mon,  7 Aug 2006 17:45:01 +0200
+
 libparams-classify-perl (0.000-2) unstable; urgency=low
 
   * Adjusted perl dependency (as told by Florian)

Modified: packages/libparams-classify-perl/trunk/debian/compat
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libparams-classify-perl/trunk/debian/compat?rev=3424&op=diff
==============================================================================
--- packages/libparams-classify-perl/trunk/debian/compat (original)
+++ packages/libparams-classify-perl/trunk/debian/compat Mon Aug  7 15:48:34 2006
@@ -1,1 +1,1 @@
-4
+5

Modified: packages/libparams-classify-perl/trunk/debian/control
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libparams-classify-perl/trunk/debian/control?rev=3424&op=diff
==============================================================================
--- packages/libparams-classify-perl/trunk/debian/control (original)
+++ packages/libparams-classify-perl/trunk/debian/control Mon Aug  7 15:48:34 2006
@@ -2,9 +2,9 @@
 Section: perl
 Priority: optional
 Maintainer: Debian Perl Group <pkg-perl-maintainers at lists.alioth.debian.org>
-Uploaders: Florian Ragwitz <florian at mookooh.org>, Joachim Breitner <nomeata at debian.org>
-Build-Depends: debhelper (>= 4.0.0), perl (>= 5.8.3-1)
-Standards-Version: 3.6.1
+Uploaders: Florian Ragwitz <florian at mookooh.org>, Joachim Breitner <nomeata at debian.org>, gregor herrmann <gregor+debian at comodo.priv.at>
+Build-Depends: debhelper (>= 5.0.0), perl (>= 5.8.3-1)
+Standards-Version: 3.7.2
 
 Package: libparams-classify-perl
 Architecture: all

Modified: packages/libparams-classify-perl/trunk/debian/rules
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libparams-classify-perl/trunk/debian/rules?rev=3424&op=diff
==============================================================================
--- packages/libparams-classify-perl/trunk/debian/rules (original)
+++ packages/libparams-classify-perl/trunk/debian/rules Mon Aug  7 15:48:34 2006
@@ -32,6 +32,11 @@
 	dh_installdirs
 	$(MAKE) install DESTDIR=$(CURDIR)/debian/libparams-classify-perl
 
+	#As this is a architecture independent package, we are not supposed to install
+	#stuff to /usr/lib. MakeMaker creates the dirs, we delete them from the deb:
+	rmdir --ignore-fail-on-non-empty --parents $(CURDIR)/debian/libparams-classify-perl/usr/lib/perl5
+                        	
+
 # Build architecture-independent files here.
 binary-indep: build install
 	dh_testdir

Modified: packages/libparams-classify-perl/trunk/lib/Params/Classify.pm
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libparams-classify-perl/trunk/lib/Params/Classify.pm?rev=3424&op=diff
==============================================================================
--- packages/libparams-classify-perl/trunk/lib/Params/Classify.pm (original)
+++ packages/libparams-classify-perl/trunk/lib/Params/Classify.pm Mon Aug  7 15:48:34 2006
@@ -52,9 +52,9 @@
 use strict;
 
 use Exporter;
-use Scalar::Util qw(blessed looks_like_number reftype);
-
-our $VERSION = "0.000";
+use Scalar::Util 1.10 qw(blessed reftype);
+
+our $VERSION = "0.001";
 
 our @ISA = qw(Exporter);
 
@@ -176,17 +176,6 @@
 This returns true iff ARG is defined and an ordinary scalar (i.e.,
 satisfies C<is_string> above) and is an acceptable number to Perl.
 This is what one usually thinks of as a number.
-
-This differs from C<looks_like_number> (see
-L<Scalar::Util/looks_like_number>; also L<perlapi/looks_like_number>
-for a lower-level description) in excluding C<undef>, typeglobs,
-and references.  Why C<looks_like_number> returns true for C<undef>
-or typeglobs is anybody's guess.  References, if treated as numbers,
-evaluate to the address in memory that they reference; this is useful
-for comparing references for equality, but it is not otherwise useful
-to treat references as numbers.  Blessed references may have overloaded
-numeric operators, but if so then they don't necessarily behave like
-ordinary numbers.
 
 Note that simple (C<is_string>-satisfying) scalars may have independent
 numeric and string values, despite the usual pretence that they have
@@ -201,15 +190,31 @@
 is sufficient to collapse it to an ordinary number if you want the
 numeric value in string form.
 
-=cut
-
-# Note: looks_like_number() returning true for undef and typeglobs appears
-# to be a bug in perl.  It's present in v5.8.3 and reported as bug ID
-# #27606.  Without this bug we wouldn't need the defined($arg) test below.
+A number may be either a native integer or a native floating point value.
+There are several subtypes of floating point value.  For classification
+among floating point values see L<Data::Float>.
+
+This function differs from C<looks_like_number> (see
+L<Scalar::Util/looks_like_number>; also L<perlapi/looks_like_number>
+for a lower-level description) in excluding C<undef>, typeglobs,
+and references.  Why C<looks_like_number> returns true for C<undef>
+or typeglobs is anybody's guess.  References, if treated as numbers,
+evaluate to the address in memory that they reference; this is useful
+for comparing references for equality, but it is not otherwise useful
+to treat references as numbers.  Blessed references may have overloaded
+numeric operators, but if so then they don't necessarily behave like
+ordinary numbers.  C<looks_like_number> is also confused by dualvars:
+it looks at the string portion of the scalar.
+
+=cut
 
 sub is_number($) {
 	my($arg) = @_;
-	defined($arg) && reftype(\$arg) eq "SCALAR" && looks_like_number($arg);
+	return 0 unless defined($arg) && reftype(\$arg) eq "SCALAR";
+	my $warned;
+	local $SIG{__WARN__} = sub { $warned = 1; };
+	{ no warnings "void"; 0 + $arg; }
+	return !$warned;
 }
 
 =back
@@ -388,6 +393,7 @@
 
 =head1 SEE ALSO
 
+L<Data::Float>,
 L<Params::Validate>,
 L<Scalar::Util>
 
@@ -397,7 +403,7 @@
 
 =head1 COPYRIGHT
 
-Copyright (C) 2004 Andrew Main (Zefram) <zefram at fysh.org>
+Copyright (C) 2004, 2006 Andrew Main (Zefram) <zefram at fysh.org>
 
 This module is free software; you can redistribute it and/or modify it
 under the same terms as Perl itself.

Modified: packages/libparams-classify-perl/trunk/t/ref.t
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libparams-classify-perl/trunk/t/ref.t?rev=3424&op=diff
==============================================================================
--- packages/libparams-classify-perl/trunk/t/ref.t (original)
+++ packages/libparams-classify-perl/trunk/t/ref.t Mon Aug  7 15:48:34 2006
@@ -29,4 +29,9 @@
 test_ref_type([], "ARRAY");
 test_ref_type({}, "HASH");
 test_ref_type(\&is, "CODE");
-test_ref_type(*foo{FORMAT}, "FORMAT");
+
+SKIP: {
+	my $format = *foo{FORMAT};
+	skip "this Perl doesn't do *foo{FORMAT}", 9 unless defined $format;
+	test_ref_type($format, "FORMAT");
+}




More information about the Pkg-perl-cvs-commits mailing list