Inital support for Q_D/Q_Q declarations.

This commit is contained in:
Roberto Raggi
2009-11-30 16:30:21 +01:00
parent 5fc8324b8b
commit 527a9bd526
18 changed files with 185 additions and 29 deletions

View File

@@ -65,7 +65,7 @@ static inline int classify2(const char *s, bool) {
return T_IDENTIFIER;
}
static inline int classify3(const char *s, bool) {
static inline int classify3(const char *s, bool q) {
if (s[0] == 'a') {
if (s[1] == 's') {
if (s[2] == 'm') {
@@ -101,6 +101,16 @@ static inline int classify3(const char *s, bool) {
}
}
}
else if (q && s[0] == 'Q') {
if (s[1] == '_') {
if (s[2] == 'D') {
return T_Q_D;
}
else if (s[2] == 'Q') {
return T_Q_Q;
}
}
}
return T_IDENTIFIER;
}