Surely bitwise bool and logical bool should render the same results.
Unfortunately, no. Bitwise operators don't do short-circuit evaluation like logical operators do, so you make be having a short-circuit evaluation problem. How? I don't know, my best guess would be if your code depended on rsi->getRsi() being called...does it?
Of course, I'm assuming that floating point inaccuracies aren't the problem...
These results are the same across thousands of entries. Logical "and" seems to return the correct bool result in test 2, but the result for bool when combining the two individual tests in test 3 returns false?? When individually initialized as in test 5 the result is correct.
Of course, I'm assuming that floating point inaccuracies aren't the problem...
Don't think there are any problems there. The data is read from the same data file for all comparisons, meaning the same data is being compared.
my best guess would be if your code depended on rsi->getRsi() being called...does it?
If by that you mean the ouput depends on the function rsi->getRsi() being called, then that would be correct. I have displayed a number of test results in my reply to LBEaston above. Perhaps that will clarify.
LB, it seems even though I was reading from the same file floating point inaccuracies did creep in. Weird since I was using the same function to format the data in both calls. I have found a solution. Thanks for your help guys!