For regular numbers, this is works, but it also claims
'integerness' for things like '2na' and '4ever'. Would
a regexp be a reliable way of catching this, or is there
something better?
sub is_int
{
($_[0] =~ /^\-?\d+(?:\.\d+)?(?:e\+\d+)?$/
&& $_[0] == int $_[0]);
}