Why do Java octal escapes only go up to 255?
问题 The Java language specification states that the escapes inside strings are the "normal" C ones like \n and \t , but they also specify octal escapes from \0 to \377 . Specifically, the JLS states: OctalEscape: \ OctalDigit \ OctalDigit OctalDigit \ ZeroToThree OctalDigit OctalDigit OctalDigit: one of 0 1 2 3 4 5 6 7 ZeroToThree: one of 0 1 2 3 meaning that something like \4715 is illegal, despite it being within the range of a Java character (since Java characters are not bytes). Why does Java