From 3cdd48067c8c865d050a19766948d05c86ec6e40 Mon Sep 17 00:00:00 2001 From: Roberto Raggi Date: Fri, 3 Jul 2009 09:11:52 +0200 Subject: Introduced ForeachStatementAST and the bits to parse foreach statements when qtMocRun is enabled. --- src/shared/cplusplus/Keywords.cpp | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) (limited to 'src/shared/cplusplus/Keywords.cpp') diff --git a/src/shared/cplusplus/Keywords.cpp b/src/shared/cplusplus/Keywords.cpp index e1b605668a..e26244a0af 100644 --- a/src/shared/cplusplus/Keywords.cpp +++ b/src/shared/cplusplus/Keywords.cpp @@ -297,7 +297,7 @@ static inline int classify5(const char *s, bool q) { if (s[2] == 'o') { if (s[3] == 't') { if (s[4] == 's') { - return T_SLOTS; + return T_Q_SLOTS; } } } @@ -627,7 +627,7 @@ static inline int classify7(const char *s, bool q) { if (s[4] == 'a') { if (s[5] == 'l') { if (s[6] == 's') { - return T_SIGNALS; + return T_Q_SIGNALS; } } } @@ -687,7 +687,7 @@ static inline int classify7(const char *s, bool q) { if (s[4] == 'O') { if (s[5] == 'T') { if (s[6] == 'S') { - return T_SLOTS; + return T_Q_SLOTS; } } } @@ -950,7 +950,21 @@ static inline int classify9(const char *s, bool q) { if (s[6] == 'A') { if (s[7] == 'L') { if (s[8] == 'S') { - return T_SIGNALS; + return T_Q_SIGNALS; + } + } + } + } + } + } + } else if (s[2] == 'F') { + if (s[3] == 'O') { + if (s[4] == 'R') { + if (s[5] == 'E') { + if (s[6] == 'A') { + if (s[7] == 'C') { + if (s[8] == 'H') { + return T_Q_FOREACH; } } } -- cgit v1.2.1