From c52acf7622ec3696ee8396bbc9e2ce55f006217d Mon Sep 17 00:00:00 2001 From: David Hilvert Date: Wed, 25 Jun 2008 00:20:51 +0000 Subject: [PATCH] Add parentheses to logical expressions to eliminate compiler warnings. --- d2/tfile.h | 8 ++++---- d2/trans_multi.h | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/d2/tfile.h b/d2/tfile.h index 62ba308..3147be7 100644 --- a/d2/tfile.h +++ b/d2/tfile.h @@ -522,8 +522,8 @@ static inline transformation tload_next(struct tload_t *t, int is_p, mc2 = default_transform.get_current_coordinate(); if (mc1.degree < mc2.degree - || mc1.degree == mc2.degree && mc1.y < mc2.y - || mc1.degree == mc2.degree && mc1.y == mc2.y && mc1.x < mc2.x) + || (mc1.degree == mc2.degree && mc1.y < mc2.y) + || (mc1.degree == mc2.degree && mc1.y == mc2.y && mc1.x < mc2.x)) break; if (mc1.degree != mc2.degree || mc1.x != mc2.x @@ -593,8 +593,8 @@ static inline transformation tload_next(struct tload_t *t, int is_p, mc2 = default_transform.get_current_coordinate(); if (mc1.degree < mc2.degree - || mc1.degree == mc2.degree && mc1.y < mc2.y - || mc1.degree == mc2.degree && mc1.y == mc2.y && mc1.x < mc2.x) + || (mc1.degree == mc2.degree && mc1.y < mc2.y) + || (mc1.degree == mc2.degree && mc1.y == mc2.y && mc1.x < mc2.x)) break; if (mc1.degree != mc2.degree || mc1.x != mc2.x diff --git a/d2/trans_multi.h b/d2/trans_multi.h index fe46d1a..b89fde9 100644 --- a/d2/trans_multi.h +++ b/d2/trans_multi.h @@ -39,8 +39,8 @@ public: public: int operator<(const multi_coordinate &mc) const { if (degree < mc.degree - || degree == mc.degree && y < mc.y - || degree == mc.degree && y == mc.y && x < mc.x) + || (degree == mc.degree && y < mc.y) + || (degree == mc.degree && y == mc.y && x < mc.x)) return 1; return 0; -- 2.11.4.GIT