Make signum and compareTo check for interrupts
Bug: 68670525
Unless we check for interrupts some comparisons will run forever
uninterruptibly.
If the client, for example, compares sqrt(11) - sqrt(11) to zero,
and then interrupts, it may still take quite a while for the interrupt
to be recognized, since each iteration of the compare loop can take
seconds. For the Android Calculator, this is usually not directly
visible, except that the compute thread will continue to use cpu
for several seconds.
Test: Ran Android calculator tests, manually exercised this case.
Change-Id: I0fe0922a8ee68bf0e08ce59c0d8c372ad10ef419
1 file changed