sugita(at)sra(dot)co(dot)jp writes:
> Attached is a patch to accept the smallest value of int8.
This has been proposed before. The problem with it is that it's
not portable: the C standard does not specify the direction of rounding
of integer division when the dividend is negative. So the test
inside the loop that tries to detect overflow would be likely to fail
on some machines.
If you can see a way around that, we're all ears ...
regards, tom lane