diff options
author | bloodstalker <thabogre@gmail.com> | 2020-03-06 23:13:00 +0000 |
---|---|---|
committer | bloodstalker <thabogre@gmail.com> | 2020-03-06 23:13:00 +0000 |
commit | f38997774cb41fba555347d5d47a08976362c41b (patch) | |
tree | ab20080e06d4db784a6dc78f330784be5dc264fd /cgrep.cpp | |
parent | updated the man and readme. (diff) | |
download | cgrep-f38997774cb41fba555347d5d47a08976362c41b.tar.gz cgrep-f38997774cb41fba555347d5d47a08976362c41b.zip |
coverage
Diffstat (limited to 'cgrep.cpp')
-rw-r--r-- | cgrep.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -601,8 +601,9 @@ public: if (!Devi::IsTheMatchInMainFile(CO_MAINFILE, MR, SL)) return void(); const NamedDecl *ND = CE->getDirectCallee(); - if (ND) + if (ND == nullptr) { return void(); + } std::string name = ND->getNameAsString(); if (regex_handler(REGEX_PP(CO_REGEX), name)) { ast_type_traits::DynTypedNode DTN = @@ -633,8 +634,9 @@ public: if (!Devi::IsTheMatchInMainFile(CO_MAINFILE, MR, SL)) return void(); const NamedDecl *ND = CE->getDirectCallee(); - if (ND) + if (ND == nullptr) { return void(); + } std::string name = ND->getNameAsString(); if (regex_handler(REGEX_PP(CO_REGEX), name)) { ast_type_traits::DynTypedNode DNode = |