(int hexdig)
| 654 | } |
| 655 | |
| 656 | private int hexval(int hexdig) { |
| 657 | if (hexdig >= '0' && hexdig <= '9') { |
| 658 | return hexdig - '0'; |
| 659 | } else if (hexdig >= 'A' && hexdig <= 'F') { |
| 660 | return hexdig + (10 - 'A'); |
| 661 | } else if (hexdig >= 'a' && hexdig <= 'f') { |
| 662 | return hexdig + (10 - 'a'); |
| 663 | } |
| 664 | throw err("invalid hex digit"); |
| 665 | } |
| 666 | |
| 667 | // backslash has already been read when this is called |
| 668 | private char readEscapedChar() throws IOException { |