------------------------------------------------------------------ */ decBiStr -- compare string with pairwise options */ / targ is the string to compare */ str1 is one of the strings to compare against (length may be 0) */ str2 is the other; it must be the same length as str1 */ / returns 1 if strings compare equal, (that is, it is
| 7663 | /* if (decBiStr(test, "mike", "MIKE")) ... */ |
| 7664 | /* ------------------------------------------------------------------ */ |
| 7665 | static Flag decBiStr(const char *targ, const char *str1, const char *str2) { |
| 7666 | for (;;targ++, str1++, str2++) { |
| 7667 | if (*targ!=*str1 && *targ!=*str2) return 0; |
| 7668 | // *targ has a match in one (or both, if terminator) |
| 7669 | if (*targ=='\0') break; |
| 7670 | } // forever |
| 7671 | return 1; |
| 7672 | } // decBiStr |
| 7673 | |
| 7674 | /* ------------------------------------------------------------------ */ |
| 7675 | /* decNaNs -- handle NaN operand or operands */ |
no outgoing calls
no test coverage detected