Return whether the characters a and b match. * @param c [out] the consensus character */
| 63 | * @param c [out] the consensus character |
| 64 | */ |
| 65 | static bool isMatch(char a, char b, char& c) |
| 66 | { |
| 67 | if (a == b) { |
| 68 | c = a; |
| 69 | } else if (toupper(a) == toupper(b)) { |
| 70 | c = islower(a) || islower(b) ? tolower(a) : a; |
| 71 | } else if (a == 'N' || a == 'n') { |
| 72 | c = b; |
| 73 | } else if (b == 'N' || b == 'n') { |
| 74 | c = a; |
| 75 | } else { |
| 76 | c = ambiguityOr(a, b); |
| 77 | return ambiguityIsSubset(a, b); |
| 78 | } |
| 79 | return true; |
| 80 | } |
| 81 | |
| 82 | /** Return the score of the alignment of a and b. */ |
| 83 | static int matchScore(const char a, const char b) |
no test coverage detected