Go to the documentation of this file.
27 for (
const char *p =
g_strToken.data(); *p != 0; p++)
29 if (*p >=
'0' && *p <=
'7') val = val * 8 + *p -
'0';
37 for (
const char *p =
g_strToken.data(); *p != 0; p++)
39 if (*p >=
'0' && *p <=
'9') val = val * 10 + *p -
'0';
47 for (
const char *p =
g_strToken.data(); *p != 0; p++)
49 if (*p >=
'0' && *p <=
'9') val = val * 16 + *p -
'0';
50 else if (*p >=
'a' && *p <=
'f') val = val * 16 + *p -
'a' + 10;
51 else if (*p >=
'A' && *p <=
'F') val = val * 16 + *p -
'A' + 10;
63 case 'n':
return CPPValue((
long)
'\n');
64 case 't':
return CPPValue((
long)
'\t');
65 case 'v':
return CPPValue((
long)
'\v');
66 case 'b':
return CPPValue((
long)
'\b');
67 case 'r':
return CPPValue((
long)
'\r');
68 case 'f':
return CPPValue((
long)
'\f');
69 case 'a':
return CPPValue((
long)
'\a');
70 case '\\':
return CPPValue((
long)
'\\');
71 case '?':
return CPPValue((
long)
'\?');
72 case '\'':
return CPPValue((
long)
'\'');
73 case '"':
return CPPValue((
long)
'"');
85 default: printf(
"Invalid escape sequence %s found!\n",
g_strToken.data());