Codebase list libdata-float-perl / c700988
New upstream version 0.013 Angel Abad 6 years ago
9 changed file(s) with 126 addition(s) and 141 deletion(s). Raw diff Collapse all Expand all
3131 },
3232 dynamic_config => 0,
3333 meta_add => { distribution_type => "module" },
34 create_makefile_pl => "passthrough",
34 meta_merge => {
35 "meta-spec" => { version => "2" },
36 resources => {
37 bugtracker => {
38 mailto => "bug-Data-Float\@rt.cpan.org",
39 web => "https://rt.cpan.org/Public/Dist/".
40 "Display.html?Name=Data-Float",
41 },
42 },
43 },
3544 sign => 1,
3645 )->create_build_script;
3746
0 version 0.013; 2017-07-29
1
2 * no longer include a Makefile.PL in the distribution
3
4 * in documentation, use four-column indentation for all verbatim
5 material
6
7 * in META.{yml,json}, point to public bug tracker
8
09 version 0.012; 2012-02-04
110
211 * include META.json in distribution
33 MANIFEST
44 META.json
55 META.yml
6 Makefile.PL
76 README
87 lib/Data/Float.pm
98 t/class.t
33 "Andrew Main (Zefram) <zefram@fysh.org>"
44 ],
55 "dynamic_config" : 0,
6 "generated_by" : "Module::Build version 0.38, CPAN::Meta::Converter version 2.112621",
6 "generated_by" : "Module::Build version 0.4224",
77 "license" : [
88 "perl_5"
99 ],
1010 "meta-spec" : {
1111 "url" : "http://search.cpan.org/perldoc?CPAN::Meta::Spec",
12 "version" : "2"
12 "version" : 2
1313 },
1414 "name" : "Data-Float",
1515 "prereqs" : {
1616 "build" : {
1717 "requires" : {
18 "Module::Build" : 0,
19 "Test::More" : 0,
18 "Module::Build" : "0",
19 "Test::More" : "0",
2020 "perl" : "5.006",
21 "strict" : 0,
22 "warnings" : 0
21 "strict" : "0",
22 "warnings" : "0"
2323 }
2424 },
2525 "configure" : {
2626 "requires" : {
27 "Module::Build" : 0,
27 "Module::Build" : "0",
2828 "perl" : "5.006",
29 "strict" : 0,
30 "warnings" : 0
29 "strict" : "0",
30 "warnings" : "0"
3131 }
3232 },
3333 "runtime" : {
3434 "requires" : {
35 "Carp" : 0,
36 "Exporter" : 0,
37 "constant" : 0,
38 "integer" : 0,
39 "parent" : 0,
35 "Carp" : "0",
36 "Exporter" : "0",
37 "constant" : "0",
38 "integer" : "0",
39 "parent" : "0",
4040 "perl" : "5.006",
41 "strict" : 0,
42 "warnings" : 0
41 "strict" : "0",
42 "warnings" : "0"
4343 }
4444 }
4545 },
4646 "provides" : {
4747 "Data::Float" : {
4848 "file" : "lib/Data/Float.pm",
49 "version" : "0.012"
49 "version" : "0.013"
5050 }
5151 },
5252 "release_status" : "stable",
5353 "resources" : {
54 "bugtracker" : {
55 "mailto" : "bug-Data-Float@rt.cpan.org",
56 "web" : "https://rt.cpan.org/Public/Dist/Display.html?Name=Data-Float"
57 },
5458 "license" : [
5559 "http://dev.perl.org/licenses/"
5660 ]
5761 },
58 "version" : "0.012"
62 "version" : "0.013",
63 "x_serialization_backend" : "JSON::PP version 2.93"
5964 }
22 author:
33 - 'Andrew Main (Zefram) <zefram@fysh.org>'
44 build_requires:
5 Module::Build: 0
6 Test::More: 0
7 perl: 5.006
8 strict: 0
9 warnings: 0
5 Module::Build: '0'
6 Test::More: '0'
7 perl: '5.006'
8 strict: '0'
9 warnings: '0'
1010 configure_requires:
11 Module::Build: 0
12 perl: 5.006
13 strict: 0
14 warnings: 0
11 Module::Build: '0'
12 perl: '5.006'
13 strict: '0'
14 warnings: '0'
1515 dynamic_config: 0
16 generated_by: 'Module::Build version 0.38, CPAN::Meta::Converter version 2.112621'
16 generated_by: 'Module::Build version 0.4224, CPAN::Meta::Converter version 2.150010'
1717 license: perl
1818 meta-spec:
1919 url: http://module-build.sourceforge.net/META-spec-v1.4.html
20 version: 1.4
20 version: '1.4'
2121 name: Data-Float
2222 provides:
2323 Data::Float:
2424 file: lib/Data/Float.pm
25 version: 0.012
25 version: '0.013'
2626 requires:
27 Carp: 0
28 Exporter: 0
29 constant: 0
30 integer: 0
31 parent: 0
32 perl: 5.006
33 strict: 0
34 warnings: 0
27 Carp: '0'
28 Exporter: '0'
29 constant: '0'
30 integer: '0'
31 parent: '0'
32 perl: '5.006'
33 strict: '0'
34 warnings: '0'
3535 resources:
36 bugtracker: https://rt.cpan.org/Public/Dist/Display.html?Name=Data-Float
3637 license: http://dev.perl.org/licenses/
37 version: 0.012
38 version: '0.013'
39 x_serialization_backend: 'CPAN::Meta::YAML version 0.012'
+0
-35
Makefile.PL less more
0 # Note: this file was auto-generated by Module::Build::Compat version 0.3800
1 require 5.006;
2
3 unless (eval "use Module::Build::Compat 0.02; 1" ) {
4 print "This module requires Module::Build to install itself.\n";
5
6 require ExtUtils::MakeMaker;
7 my $yn = ExtUtils::MakeMaker::prompt
8 (' Install Module::Build now from CPAN?', 'y');
9
10 unless ($yn =~ /^y/i) {
11 die " *** Cannot install without Module::Build. Exiting ...\n";
12 }
13
14 require Cwd;
15 require File::Spec;
16 require CPAN;
17
18 # Save this 'cause CPAN will chdir all over the place.
19 my $cwd = Cwd::cwd();
20
21 CPAN::Shell->install('Module::Build::Compat');
22 CPAN::Shell->expand("Module", "Module::Build::Compat")->uptodate
23 or die "Couldn't install Module::Build, giving up.\n";
24
25 chdir $cwd or die "Cannot chdir() back to $cwd: $!";
26 }
27 eval "use Module::Build::Compat 0.02; 1" or die $@;
28
29 Module::Build::Compat->run_build_pl(args => \@ARGV);
30 my $build_script = 'Build';
31 $build_script .= '.com' if $^O eq 'VMS';
32 exit(0) unless(-e $build_script); # cpantesters convention
33 require Module::Build;
34 Module::Build::Compat->write_makefile(build_class => 'Module::Build');
2222
2323 COPYRIGHT
2424
25 Copyright (C) 2006, 2007, 2008, 2010, 2012
25 Copyright (C) 2006, 2007, 2008, 2010, 2012, 2017
2626 Andrew Main (Zefram) <zefram@fysh.org>
2727
2828 LICENSE
00 This file contains message digests of all files listed in MANIFEST,
1 signed via the Module::Signature module, version 0.68.
1 signed via the Module::Signature module, version 0.81.
22
33 To verify the content in this distribution, first make sure you have
44 Module::Signature installed, then type:
1414 Hash: SHA1
1515
1616 SHA1 67ab6441ac84593b05be87ec425194d069a51a4f .gitignore
17 SHA1 22c0b8256338e7f077f6311527c006ca9acfc75b Build.PL
18 SHA1 ca759dce347033b09e9ae85304e9afa352f97e6b Changes
19 SHA1 739118525532c8ff18c2f9ec7a929501d610088a MANIFEST
20 SHA1 c842f45a8761f35bb77ce7cff3e1bde66826d4c2 META.json
21 SHA1 83ade225100dc05a2d06033c44cd317609f97efb META.yml
22 SHA1 a4df8e97ccd390a42212af5a9f4d0986c85e7a5f Makefile.PL
23 SHA1 6f2a34c998a573556ecc84049f01bc1deb30d860 README
24 SHA1 f3398878f29a6e567c17b98caa25ffa15c857033 lib/Data/Float.pm
17 SHA1 51038d8df8e8a4aa29c0b5462db2a554079dd1d4 Build.PL
18 SHA1 083de6c6b8b9b82eabc05f87708086791c66d14a Changes
19 SHA1 efa3ba002e530881eb04ceb66df34f8d5151e6ee MANIFEST
20 SHA1 3d9fb5d89a73d9dd7dd9ce83e05d6b9f58e8b274 META.json
21 SHA1 093974afafda5e5df08e79ecdf9f553c7d8864d5 META.yml
22 SHA1 0e70e74666ed9702cbce0899ed0a2e759c532b0c README
23 SHA1 7d2f83d9e82cc04b8f03716373f6e4f963da5079 lib/Data/Float.pm
2524 SHA1 1108747d9aec62d4eadd34403fa59f1c54df153f t/class.t
2625 SHA1 eba7f4eeb285767f6546eebdca9cd07011b4dd51 t/const.t
2726 SHA1 a4ee7a6b431b6e5ee3872ff2dba90663c28148d7 t/copysign.t
3332 SHA1 65c75abdef6f01a5d1588a307f2ddfe2333dc961 t/pod_syn.t
3433 SHA1 3369ba662006149c6e5a089e6f2a440367f6df64 t/pow2.t
3534 -----BEGIN PGP SIGNATURE-----
36 Version: GnuPG v1.4.10 (GNU/Linux)
35 Version: GnuPG v1
3736
38 iEYEARECAAYFAk8tRHMACgkQOV9mt2VyAVHh0QCfTJyr4UoKGJNnpJBYoNRMt0st
39 0DsAniDJ01nBya7tjOZrcDPqJ9zv5ynU
40 =rIt7
37 iEYEARECAAYFAll85HQACgkQOV9mt2VyAVG57wCfWtVZY5fr+Sm2iKataje2u6s8
38 HsIAoJaNsFJB2s+xS3UlCJdqvXRe103v
39 =fbmx
4140 -----END PGP SIGNATURE-----
33
44 =head1 SYNOPSIS
55
6 use Data::Float qw(have_signed_zero);
7
8 if(have_signed_zero) { ...
9
10 # and many other constants; see text
11
12 use Data::Float qw(
13 float_class float_is_normal float_is_subnormal
14 float_is_nzfinite float_is_zero float_is_finite
15 float_is_infinite float_is_nan
16 );
17
18 $class = float_class($value);
19
20 if(float_is_normal($value)) { ...
21 if(float_is_subnormal($value)) { ...
22 if(float_is_nzfinite($value)) { ...
23 if(float_is_zero($value)) { ...
24 if(float_is_finite($value)) { ...
25 if(float_is_infinite($value)) { ...
26 if(float_is_nan($value)) { ...
27
28 use Data::Float qw(float_sign signbit float_parts);
29
30 $sign = float_sign($value);
31 $sign_bit = signbit($value);
32 ($sign, $exponent, $significand) = float_parts($value);
33
34 use Data::Float qw(float_hex hex_float);
35
36 print float_hex($value);
37 $value = hex_float($string);
38
39 use Data::Float qw(float_id_cmp totalorder);
40
41 @sorted_floats = sort { float_id_cmp($a, $b) } @floats;
42 if(totalorder($a, $b)) { ...
43
44 use Data::Float qw(
45 pow2 mult_pow2 copysign
46 nextup nextdown nextafter
47 );
48
49 $x = pow2($exp);
50 $x = mult_pow2($value, $exp);
51 $x = copysign($magnitude, $sign_from);
52 $x = nextup($x);
53 $x = nextdown($x);
54 $x = nextafter($x, $direction);
6 use Data::Float qw(have_signed_zero);
7
8 if(have_signed_zero) { ...
9
10 # and many other constants; see text
11
12 use Data::Float qw(
13 float_class float_is_normal float_is_subnormal
14 float_is_nzfinite float_is_zero float_is_finite
15 float_is_infinite float_is_nan);
16
17 $class = float_class($value);
18
19 if(float_is_normal($value)) { ...
20 if(float_is_subnormal($value)) { ...
21 if(float_is_nzfinite($value)) { ...
22 if(float_is_zero($value)) { ...
23 if(float_is_finite($value)) { ...
24 if(float_is_infinite($value)) { ...
25 if(float_is_nan($value)) { ...
26
27 use Data::Float qw(float_sign signbit float_parts);
28
29 $sign = float_sign($value);
30 $sign_bit = signbit($value);
31 ($sign, $exponent, $significand) = float_parts($value);
32
33 use Data::Float qw(float_hex hex_float);
34
35 print float_hex($value);
36 $value = hex_float($string);
37
38 use Data::Float qw(float_id_cmp totalorder);
39
40 @sorted_floats = sort { float_id_cmp($a, $b) } @floats;
41 if(totalorder($a, $b)) { ...
42
43 use Data::Float qw(
44 pow2 mult_pow2 copysign nextup nextdown nextafter);
45
46 $x = pow2($exp);
47 $x = mult_pow2($value, $exp);
48 $x = copysign($magnitude, $sign_from);
49 $x = nextup($x);
50 $x = nextdown($x);
51 $x = nextafter($x, $direction);
5552
5653 =head1 DESCRIPTION
5754
177174
178175 use Carp qw(croak);
179176
180 our $VERSION = "0.012";
177 our $VERSION = "0.013";
181178
182179 use parent "Exporter";
183180 our @EXPORT_OK = qw(
13841381
13851382 =head1 COPYRIGHT
13861383
1387 Copyright (C) 2006, 2007, 2008, 2010, 2012
1384 Copyright (C) 2006, 2007, 2008, 2010, 2012, 2017
13881385 Andrew Main (Zefram) <zefram@fysh.org>
13891386
13901387 =head1 LICENSE