Commit 2238501
Stefan Krah
Many cleanups of redundant code in mpd_qrem_near():
1) _mpd_qdivmod() uses the context precision only in two places, and
the new code should be exactly equivalent to the previous code.
2) Remove misleading comment.
3) The quotient *is* an integer with exponent 0, so calling mpd_qtrunc()
is pointless.
4) Replace two instances of identical code by a single one.
5) Use _mpd_cmp_abs() instead of mpd_cmp_total_mag(): the operands
are not special.
6) Don't clear MPD_Rounded in the status (with the current code it should
not be set within the function).1 parent 42c9b04 commit 2238501
1 file changed
Lines changed: 15 additions & 23 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6679 | 6679 | | |
6680 | 6680 | | |
6681 | 6681 | | |
6682 | | - | |
| 6682 | + | |
6683 | 6683 | | |
6684 | 6684 | | |
6685 | 6685 | | |
| |||
6716 | 6716 | | |
6717 | 6717 | | |
6718 | 6718 | | |
6719 | | - | |
6720 | | - | |
6721 | | - | |
6722 | | - | |
6723 | | - | |
6724 | | - | |
6725 | | - | |
| 6719 | + | |
| 6720 | + | |
6726 | 6721 | | |
6727 | 6722 | | |
6728 | 6723 | | |
6729 | 6724 | | |
6730 | 6725 | | |
6731 | 6726 | | |
6732 | | - | |
6733 | | - | |
6734 | 6727 | | |
6735 | 6728 | | |
6736 | 6729 | | |
6737 | | - | |
6738 | 6730 | | |
6739 | | - | |
| 6731 | + | |
6740 | 6732 | | |
6741 | 6733 | | |
6742 | 6734 | | |
6743 | 6735 | | |
| 6736 | + | |
6744 | 6737 | | |
6745 | | - | |
6746 | | - | |
6747 | | - | |
6748 | | - | |
6749 | 6738 | | |
6750 | 6739 | | |
| 6740 | + | |
6751 | 6741 | | |
6752 | | - | |
6753 | | - | |
6754 | | - | |
6755 | | - | |
6756 | 6742 | | |
6757 | 6743 | | |
6758 | | - | |
| 6744 | + | |
| 6745 | + | |
| 6746 | + | |
| 6747 | + | |
| 6748 | + | |
| 6749 | + | |
6759 | 6750 | | |
6760 | | - | |
| 6751 | + | |
| 6752 | + | |
| 6753 | + | |
6761 | 6754 | | |
6762 | 6755 | | |
6763 | 6756 | | |
6764 | 6757 | | |
6765 | | - | |
6766 | 6758 | | |
6767 | 6759 | | |
6768 | 6760 | | |
| |||
0 commit comments