Added value range assertions to prevent static analysis false-positives on Clang.

pull/76/merge
Sherief Farouk 2013-08-07 18:43:29 -04:00
parent e9b1754306
commit c8428fa67a
1 changed files with 4 additions and 0 deletions

View File

@ -547,6 +547,10 @@ private:
default:
ai_assert(false);
}
ai_assert((order[0] >= 0) && (order[0] <= 2));
ai_assert((order[1] >= 0) && (order[1] <= 2));
ai_assert((order[2] >= 0) && (order[2] <= 2));
if(!is_id[order[0]]) {
out = temp[order[0]];