aboutsummaryrefslogtreecommitdiffstats
path: root/src/libs/3rdparty/cplusplus/ASTMatcher.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/libs/3rdparty/cplusplus/ASTMatcher.cpp')
-rw-r--r--src/libs/3rdparty/cplusplus/ASTMatcher.cpp42
1 files changed, 42 insertions, 0 deletions
diff --git a/src/libs/3rdparty/cplusplus/ASTMatcher.cpp b/src/libs/3rdparty/cplusplus/ASTMatcher.cpp
index d76180a8ca..321d14a263 100644
--- a/src/libs/3rdparty/cplusplus/ASTMatcher.cpp
+++ b/src/libs/3rdparty/cplusplus/ASTMatcher.cpp
@@ -117,6 +117,46 @@ bool ASTMatcher::match(GnuAttributeSpecifierAST *node, GnuAttributeSpecifierAST
return true;
}
+bool ASTMatcher::match(MsvcDeclspecSpecifierAST *node, MsvcDeclspecSpecifierAST *pattern)
+{
+ (void) node;
+ (void) pattern;
+
+ pattern->attribute_token = node->attribute_token;
+
+ pattern->lparen_token = node->lparen_token;
+
+ if (! pattern->attribute_list)
+ pattern->attribute_list = node->attribute_list;
+ else if (! AST::match(node->attribute_list, pattern->attribute_list, this))
+ return false;
+
+ pattern->rparen_token = node->rparen_token;
+
+ return true;
+}
+
+bool ASTMatcher::match(StdAttributeSpecifierAST *node, StdAttributeSpecifierAST *pattern)
+{
+ (void) node;
+ (void) pattern;
+
+ pattern->first_lbracket_token = node->first_lbracket_token;
+
+ pattern->second_lbracket_token = node->second_lbracket_token;
+
+ if (! pattern->attribute_list)
+ pattern->attribute_list = node->attribute_list;
+ else if (! AST::match(node->attribute_list, pattern->attribute_list, this))
+ return false;
+
+ pattern->first_rbracket_token = node->first_rbracket_token;
+
+ pattern->second_rbracket_token = node->second_rbracket_token;
+
+ return true;
+}
+
bool ASTMatcher::match(GnuAttributeAST *node, GnuAttributeAST *pattern)
{
(void) node;
@@ -1246,6 +1286,8 @@ bool ASTMatcher::match(IfStatementAST *node, IfStatementAST *pattern)
pattern->if_token = node->if_token;
+ pattern->constexpr_token = node->constexpr_token;
+
pattern->lparen_token = node->lparen_token;
if (! pattern->condition)