Returns true if ch is in [0-9A-Za-z], false otherwise.
| 943 | |
| 944 | // Returns true if ch is in [0-9A-Za-z], false otherwise. |
| 945 | bool IsHex(char ch) { |
| 946 | return ('0' <= ch && ch <= '9') || ('A' <= ch && ch <= 'F') || ('a' <= ch && ch <= 'f'); |
| 947 | } |
| 948 | |
| 949 | // Returns the hexadecimal value contained in the char. Precondition: IsHex(ch) |
| 950 | char ParseHexUnchecked(char ch) { |