src: code cleanup

* removed unused code: ParseFunction, ParseVariable and ParseTypeUsage. All this is handled using NameHierarchies now.
* Moved the getErrorCount method from ParserClient to the StorageAccess
* MessageFinishedParsing doesn't know the error count anymore.
* StatusBarController now has a StorageAccess to fetch the error count when needed.
This commit is contained in:
malte_langkabel
2016-03-07 10:59:39 +01:00
parent 5cdaafc6de
commit 6d7a1faaa4
25 changed files with 121 additions and 590 deletions
-31
View File
@@ -2,10 +2,7 @@
#include <sstream>
#include "data/parser/ParseFunction.h"
#include "data/parser/ParseLocation.h"
#include "data/parser/ParseTypeUsage.h"
#include "data/parser/ParseVariable.h"
#include "data/type/DataType.h"
#include "utility/utilityString.h"
@@ -85,34 +82,6 @@ std::string ParserClient::addLocationSuffix(
return ss.str();
}
std::string ParserClient::variableStr(const ParseVariable& variable)
{
std::string str = variable.type.dataType->getFullTypeName() + " " + variable.getFullName();
return addStaticPrefix(str, variable.isStatic);
}
std::string ParserClient::parameterStr(const std::vector<ParseTypeUsage> parameters)
{
std::string str = "(";
for (size_t i = 0; i < parameters.size(); i++)
{
str += parameters[i].dataType->getFullTypeName();
if (i < parameters.size() - 1)
{
str += ", ";
}
}
return str + ")";
}
std::string ParserClient::functionStr(const ParseFunction& function)
{
/*std::string str =
function.returnType.dataType->getFullTypeName() + " " + function.getFullName() + parameterStr(function.parameters);
return addConstPrefix(addStaticPrefix(str, function.isStatic), function.isConst, false);*/
return function.nameHierarchy.getQualifiedNameWithSignature();
}
ParserClient::ParserClient()
{
}