diff options
Diffstat (limited to 'src/shared/cplusplus/ASTMatcher.cpp')
-rw-r--r-- | src/shared/cplusplus/ASTMatcher.cpp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/shared/cplusplus/ASTMatcher.cpp b/src/shared/cplusplus/ASTMatcher.cpp index 9ded92f8ef..b7920f767f 100644 --- a/src/shared/cplusplus/ASTMatcher.cpp +++ b/src/shared/cplusplus/ASTMatcher.cpp @@ -274,6 +274,25 @@ bool ASTMatcher::match(QtMethodAST *node, QtMethodAST *pattern) return true; } +bool ASTMatcher::match(QtMemberDeclarationAST *node, QtMemberDeclarationAST *pattern) +{ + (void) node; + (void) pattern; + + pattern->q_token = node->q_token; + + pattern->lparen_token = node->lparen_token; + + if (! pattern->type_id) + pattern->type_id = node->type_id; + else if (! AST::match(node->type_id, pattern->type_id, this)) + return false; + + pattern->rparen_token = node->rparen_token; + + return true; +} + bool ASTMatcher::match(BinaryExpressionAST *node, BinaryExpressionAST *pattern) { (void) node; |