#!perl
use 5.006;
use strict;
our $VERSION = '0.06';
use GCC::Builtins qw/:all/;
my $res = bswap32(2);
my $expected = "33554432";
if( $expected =~ /^([+-]?)(?=\d|\.\d)\d*(\.\d*)?([Ee]([+-]?\d+))?$/ ){
my $dif = abs($res-$expected);
ok($dif<1e-09, "called bswap32(2) returned ($res) and expected ($expected) values differ ($dif) by less than 1e-09.");
} else {
is(lc($res), lc($expected), "called bswap32(2) returned ($res) and expected ($expected) values are identical.");
}
diag("copy-this-expected-value 'bswap32' => '$res',");
done_testing();