Apache OpenOffice (AOO) Bugzilla – Issue 95379
tools: ambiguous operator precedence
Last modified: 2008-11-26 08:36:43 UTC
So, my recent gcc has some extra warnings about dodgy looking implicit operator precedence. The following patch just enforces the current implicit operator precedence, i.e. << before & before | before && before || so it changes nothing except to make those warnings go away. It all looks ok except maybe for source/fsys/urlobj.cxx where we have... while (p != pEnd && INetMIME::isHexDigit(*p) || *p == ':' || *p == '.') where a && b || c || d is effectively (((a && b) || c) || d) i.e. while ((p != pEnd && INetMIME::isHexDigit(*p)) || *p == ':' || *p == '.') is this what is truly intended or is it intended to be while (p != pEnd && (INetMIME::isHexDigit(*p) || *p == ':' || *p == '.'))
Created attachment 57417 [details] patch, that assumes implicit precedence is correct
cd->sb: Could you please check the patch from Caolan.
@cmc: The fix for source/fsys/urlobj.cxx should read while (p != pEnd && (INetMIME::isHexDigit(*p) || *p == ':' || *p == '.')) (i.e., the current code is wrong, and the extra warning helped find an error). Either integrate yourself, or pass back to me and I will add it to some CWS...
will take for cmcfixes50
done
cmc->sb: happy to verify this in cmcfixes50 ?
set to "verified" as its the agreed patch
.