summaryrefslogtreecommitdiff
path: root/longlong.h
diff options
context:
space:
mode:
authorMarc Glisse <marc.glisse@inria.fr>2016-08-22 23:15:56 +0200
committerMarc Glisse <marc.glisse@inria.fr>2016-08-22 23:15:56 +0200
commit889915a509fc49acf7cfc37d674f1b43436981ab (patch)
tree2df479d0756b7332eb788093812c68fecae8c4a6 /longlong.h
parent2df52ea31ca8722b3ab371eb40450cb2e40f65e5 (diff)
downloadgmp-889915a509fc49acf7cfc37d674f1b43436981ab.tar.gz
Protect umul_ppmm with do ... while (0) as recommended by Vincent Lefevre.
Diffstat (limited to 'longlong.h')
-rw-r--r--longlong.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/longlong.h b/longlong.h
index fde527703..6dedc1360 100644
--- a/longlong.h
+++ b/longlong.h
@@ -1895,11 +1895,11 @@ extern UWtype __MPN(udiv_qrnnd) (UWtype *, UWtype, UWtype, UWtype);
/* FIXME: "sidi" here is highly doubtful, should sometimes be "diti". */
#if !defined (umul_ppmm) && defined (__umulsidi3)
#define umul_ppmm(ph, pl, m0, m1) \
- { \
+ do { \
UDWtype __ll = __umulsidi3 (m0, m1); \
ph = (UWtype) (__ll >> W_TYPE_SIZE); \
pl = (UWtype) __ll; \
- }
+ } while (0)
#endif
#if !defined (__umulsidi3)