Exclusive or: true iff exactly one argument is true. The arguments are negated to ensure that they are 0/1 values. Then the bitwise Xor operator may apply. (This idea is due to Michael Baldwin.)
| 173 | // values. Then the bitwise Xor operator may apply. |
| 174 | // (This idea is due to Michael Baldwin.) |
| 175 | inline bool xorb(bool x, bool y) |
| 176 | { |
| 177 | return !x ^ !y; |
| 178 | } |
| 179 | |
| 180 | // Returns true iff c is strictly to the left of the directed |
| 181 | // line through a to b. |