1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-06-09 18:56:02 +02:00

change isoC to return a string.

This commit is contained in:
Alain Magloire 2002-10-24 13:44:05 +00:00
parent abe8e7319c
commit b8023947be

View file

@ -65,28 +65,29 @@ public class MIConst extends MIValue {
* Assuming that the precedent character was the * Assuming that the precedent character was the
* escape sequence '\' * escape sequence '\'
*/ */
private static char isoC(char c) { private static String isoC(char c) {
String s = new Character(c).toString();
if (c == '"') { if (c == '"') {
c = '"'; s = "\"";
} else if (c == '\'') { } else if (c == '\'') {
c = '\''; s = "\'";
} else if (c == '?') { } else if (c == '?') {
c = '?'; s = "?";
} else if (c == 'a') { } else if (c == 'a') {
c = 7; s = "\007";
} else if (c == 'b') { } else if (c == 'b') {
c = '\b'; s = "\b";
} else if (c == 'f') { } else if (c == 'f') {
c = '\f'; s = "\f";
} else if (c == 'n') { } else if (c == 'n') {
c = '\n'; s = System.getProperty("line.separator", "\n");
} else if (c == 'r') { } else if (c == 'r') {
c = '\r'; s = "\r";
} else if (c == 't') { } else if (c == 't') {
c = '\t'; s = "\t";
} else if (c == 'v') { } else if (c == 'v') {
c = 11; s = "\013";
} }
return c; return s;
} }
} }