apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aaron Bannert <aa...@clove.org>
Subject Re: cvs commit: apr/strings apr_strings.c
Date Tue, 20 Aug 2002 02:32:25 GMT
>   +        if ( (any < 0) || (neg && (val > acc || (val -= c) > acc))

Isn't that one of those short-circuits that causes bad side-effects
under different circumstances? I have a feeling that it is not
well defined if the -= operation is always performed or not, but
I could be wrong. Assuming I can understand what's going on here,
I'll take a shot at trying to make the logic more clear (while
keeping as much of the constant-folding/short-circuiting as possible.)


View raw message