Author: brunowolff
Date: Wed Mar 19 17:00:06 2008
New Revision: 24831
URL: http://svn.gna.org/viewcvs/wesnoth?rev=24831&view=rev
Log:
Silence gcc 4.3 warnings by adding parens around && clauses near ||.
Modified:
trunk/src/pathutils.cpp
Modified: trunk/src/pathutils.cpp
URL:
http://svn.gna.org/viewcvs/wesnoth/trunk/src/pathutils.cpp?rev=24831&r1=24830&r2=24831&view=diff
==============================================================================
--- trunk/src/pathutils.cpp (original)
+++ trunk/src/pathutils.cpp Wed Mar 19 17:00:06 2008
@@ -67,7 +67,7 @@
const int xdiff = abs(a.x - b.x);
const int ydiff = abs(a.y - b.y);
- return ydiff == 1 && a.x == b.x || xdiff == 1 && a.y == b.y ||
- xdiff == 1 && ydiff == 1 && (a.y > b.y ? is_even(a.x) :
is_even(b.x));
+ return ydiff == (1 && a.x == b.x) || (xdiff == 1 && a.y == b.y) ||
+ (xdiff == 1 && ydiff == 1 && (a.y > b.y ? is_even(a.x) :
is_even(b.x)));
}
_______________________________________________
Wesnoth-commits mailing list
[email protected]
https://mail.gna.org/listinfo/wesnoth-commits