data: fixes for clearing on refresh

* reduce aggregation count when clearing
* added TokenLocation to method override edge
* added TokenLocations to template related edges
This commit is contained in:
Eberhard Graether
2015-05-18 16:22:39 +02:00
parent f0e101e994
commit 1f3be0e60d
13 changed files with 134 additions and 48 deletions
+6 -6
View File
@@ -614,7 +614,7 @@ public:
);
TS_ASSERT_EQUALS(client->overrides.size(), 1);
TS_ASSERT_EQUALS(client->overrides[0], "void A::foo() -> void B::foo()");
TS_ASSERT_EQUALS(client->overrides[0], "void A::foo() -> void B::foo() <5:7 5:9>");
}
void test_cxx_parser_finds_no_method_override_when_not_virtual()
@@ -646,8 +646,8 @@ public:
);
TS_ASSERT_EQUALS(client->overrides.size(), 2);
TS_ASSERT_EQUALS(client->overrides[0], "void A::foo() -> void B::foo()");
TS_ASSERT_EQUALS(client->overrides[1], "void B::foo() -> void C::foo()");
TS_ASSERT_EQUALS(client->overrides[0], "void A::foo() -> void B::foo() <5:7 5:9>");
TS_ASSERT_EQUALS(client->overrides[1], "void B::foo() -> void C::foo() <8:7 8:9>");
}
void test_cxx_parser_finds_no_method_overrides_on_different_signatures()
@@ -677,7 +677,7 @@ public:
);
TS_ASSERT_EQUALS(client->overrides.size(), 1);
TS_ASSERT_EQUALS(client->overrides[0], "void A::foo() -> int B::foo()");
TS_ASSERT_EQUALS(client->overrides[0], "void A::foo() -> int B::foo() <5:6 5:8>");
TS_ASSERT_EQUALS(client->errors.size(), 1);
}
@@ -2565,9 +2565,9 @@ private:
return 0;
}
virtual Id onMethodOverrideParsed(const ParseFunction& base, const ParseFunction& overrider)
virtual Id onMethodOverrideParsed(const ParseLocation& location, const ParseFunction& base, const ParseFunction& overrider)
{
overrides.push_back(functionStr(base) + " -> " + functionStr(overrider));
overrides.push_back(addLocationSuffix(functionStr(base) + " -> " + functionStr(overrider), location));
return 0;
}