aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbloodstalker <thabogre@gmail.com>2016-11-21 01:53:49 +0000
committerbloodstalker <thabogre@gmail.com>2016-11-21 01:53:49 +0000
commit18ade7a853fe8d693c93bb8631e3ec0d970206b0 (patch)
tree72517d84dd7ad76da537049382b44865bace9fa1
parentupdated TDD tests for 8.1 (diff)
downloadmutator-18ade7a853fe8d693c93bb8631e3ec0d970206b0.tar.gz
mutator-18ade7a853fe8d693c93bb8631e3ec0d970206b0.zip
just added some comments to 8.1
-rw-r--r--mutator-lvl0.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/mutator-lvl0.cpp b/mutator-lvl0.cpp
index f94e9b2..58c8c99 100644
--- a/mutator-lvl0.cpp
+++ b/mutator-lvl0.cpp
@@ -626,6 +626,7 @@ public:
SourceLocation SL = FD->getLocStart();
SL = Devi::SourceLocationHasMacro(SL, Rewrite, "start");
+ /*going through the already matched functions,making sure we are not adding duplicates.*/
for (unsigned x = 0; x < VecC; ++x)
{
if (FuncInfoProto[x].FuncNameString == MatchedName)
@@ -646,10 +647,12 @@ public:
if (!FD->isThisDeclarationADefinition())
{
+ /*this function has a declaration that is not a definition.*/
FuncInfoProto[VecC].HasDecThatisNotDef = true;
}
else
{
+ /*save the sourcelocation only if the functiondecl is a definition.*/
FuncInfoProto[VecC].StrcSL = SL.printToString(*MR.SourceManager);
}
@@ -659,6 +662,7 @@ public:
virtual void onEndOfTranslationUnit()
{
+
for (unsigned x = 0; x < VecC; ++x)
{
if (FuncInfoProto[x].HasDecThatisNotDef == false)
@@ -667,6 +671,7 @@ public:
std::cout << FuncInfoProto[x].StrcSL << "\n" << std::endl;
}
}
+
}
private: