summaryrefslogtreecommitdiff
path: root/src/shared/cplusplus/ASTMatcher.cpp
diff options
context:
space:
mode:
authorRoberto Raggi <roberto.raggi@nokia.com>2009-11-13 15:17:27 +0100
committerRoberto Raggi <roberto.raggi@nokia.com>2009-11-13 15:17:27 +0100
commit1a7855af220156f00bdbb38a5cd53f11c6f9a0fb (patch)
treef9e3ccdadc23a8a7d76581a1ce99f52a122f4af1 /src/shared/cplusplus/ASTMatcher.cpp
parentbaffd97efb1fd6da004fedf620577f8a97445793 (diff)
downloadqt-creator-1a7855af220156f00bdbb38a5cd53f11c6f9a0fb.tar.gz
Match the value of the literals.
Diffstat (limited to 'src/shared/cplusplus/ASTMatcher.cpp')
-rw-r--r--src/shared/cplusplus/ASTMatcher.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/shared/cplusplus/ASTMatcher.cpp b/src/shared/cplusplus/ASTMatcher.cpp
index 47dac58232..5d137e9e9c 100644
--- a/src/shared/cplusplus/ASTMatcher.cpp
+++ b/src/shared/cplusplus/ASTMatcher.cpp
@@ -57,6 +57,9 @@ bool ASTMatcher::matchToken(unsigned tokenIndex, unsigned patternTokenIndex) con
else if (token.is(T_IDENTIFIER)) {
if (! token.identifier->isEqualTo(otherToken.identifier))
return false;
+ } else if (token.isLiteral()) {
+ if (! token.literal->isEqualTo(otherToken.literal))
+ return false;
}
return true;
}