From bbcebffefd5deb25a2e5650af8ffca76237130c5 Mon Sep 17 00:00:00 2001 From: Deukhoofd Date: Sun, 28 Jul 2019 12:58:38 +0200 Subject: [PATCH] Moved ScriptType classes into separate directory --- src/Binder/Binder.cpp | 2 +- src/Binder/Binder.hpp | 2 +- src/Binder/BoundExpressions/BoundExpression.hpp | 4 ++-- .../BoundStatements/BoundFunctionDeclarationStatement.hpp | 2 +- src/Binder/BoundVariables/BoundVariable.hpp | 2 +- src/Evaluator/EvalValues/EvalValue.hpp | 2 +- src/Evaluator/EvalValues/ScriptFunctionEvalValue.hpp | 4 ++-- src/Evaluator/Evaluator.cpp | 2 +- src/{ => ScriptTypes}/FunctionScriptType.cpp | 0 src/{ => ScriptTypes}/FunctionScriptType.hpp | 0 src/{ => ScriptTypes}/ScriptType.cpp | 4 ++-- src/{ => ScriptTypes}/ScriptType.hpp | 4 ++-- src/{ => ScriptTypes}/TableScriptType.hpp | 2 +- src/UserData/UserDataFunction.hpp | 2 +- src/UserData/UserDataFunctionType.hpp | 4 ++-- src/UserData/UserDataScriptType.hpp | 2 +- 16 files changed, 19 insertions(+), 19 deletions(-) rename src/{ => ScriptTypes}/FunctionScriptType.cpp (100%) rename src/{ => ScriptTypes}/FunctionScriptType.hpp (100%) rename src/{ => ScriptTypes}/ScriptType.cpp (95%) rename src/{ => ScriptTypes}/ScriptType.hpp (97%) rename src/{ => ScriptTypes}/TableScriptType.hpp (97%) diff --git a/src/Binder/Binder.cpp b/src/Binder/Binder.cpp index 6af3e19..7ef8132 100644 --- a/src/Binder/Binder.cpp +++ b/src/Binder/Binder.cpp @@ -1,7 +1,7 @@ #include #include "Binder.hpp" -#include "../TableScriptType.hpp" +#include "../ScriptTypes/TableScriptType.hpp" #include "BoundExpressions/BoundTableExpression.hpp" #include "BoundExpressions/BoundFunctionCallExpression.hpp" #include "../UserData/UserDataScriptType.hpp" diff --git a/src/Binder/Binder.hpp b/src/Binder/Binder.hpp index 96d4125..14e37b6 100644 --- a/src/Binder/Binder.hpp +++ b/src/Binder/Binder.hpp @@ -6,7 +6,7 @@ #include "../Script.hpp" #include "BoundVariables/BoundScope.hpp" #include "../Parser/ParsedExpressions/ParsedTableExpression.hpp" -#include "../FunctionScriptType.hpp" +#include "../ScriptTypes/FunctionScriptType.hpp" using namespace std; using namespace Porygon::Parser; diff --git a/src/Binder/BoundExpressions/BoundExpression.hpp b/src/Binder/BoundExpressions/BoundExpression.hpp index 69c5e82..aa496fc 100644 --- a/src/Binder/BoundExpressions/BoundExpression.hpp +++ b/src/Binder/BoundExpressions/BoundExpression.hpp @@ -4,10 +4,10 @@ #include #include #include -#include "../../ScriptType.hpp" +#include "../../ScriptTypes/ScriptType.hpp" #include "../BoundOperators.hpp" #include "../BoundVariables/BoundVariableKey.hpp" -#include "../../FunctionScriptType.hpp" +#include "../../ScriptTypes/FunctionScriptType.hpp" using namespace std; diff --git a/src/Binder/BoundStatements/BoundFunctionDeclarationStatement.hpp b/src/Binder/BoundStatements/BoundFunctionDeclarationStatement.hpp index e8f6a7c..939a4de 100644 --- a/src/Binder/BoundStatements/BoundFunctionDeclarationStatement.hpp +++ b/src/Binder/BoundStatements/BoundFunctionDeclarationStatement.hpp @@ -4,7 +4,7 @@ #include #include "BoundStatement.hpp" -#include "../../FunctionScriptType.hpp" +#include "../../ScriptTypes/FunctionScriptType.hpp" namespace Porygon::Binder { class BoundFunctionDeclarationStatement : public BoundStatement { diff --git a/src/Binder/BoundVariables/BoundVariable.hpp b/src/Binder/BoundVariables/BoundVariable.hpp index 03f41f7..b13e84c 100644 --- a/src/Binder/BoundVariables/BoundVariable.hpp +++ b/src/Binder/BoundVariables/BoundVariable.hpp @@ -5,7 +5,7 @@ #include #include -#include "../../ScriptType.hpp" +#include "../../ScriptTypes/ScriptType.hpp" using namespace std; diff --git a/src/Evaluator/EvalValues/EvalValue.hpp b/src/Evaluator/EvalValues/EvalValue.hpp index ae5977f..68197ff 100644 --- a/src/Evaluator/EvalValues/EvalValue.hpp +++ b/src/Evaluator/EvalValues/EvalValue.hpp @@ -5,7 +5,7 @@ #include #include #include -#include "../../ScriptType.hpp" +#include "../../ScriptTypes/ScriptType.hpp" #include "../EvaluationException.hpp" namespace Porygon::Evaluation{ class EvalValue; diff --git a/src/Evaluator/EvalValues/ScriptFunctionEvalValue.hpp b/src/Evaluator/EvalValues/ScriptFunctionEvalValue.hpp index d2eb5b9..26aacbc 100644 --- a/src/Evaluator/EvalValues/ScriptFunctionEvalValue.hpp +++ b/src/Evaluator/EvalValues/ScriptFunctionEvalValue.hpp @@ -5,11 +5,11 @@ #include #include #include -#include "../../ScriptType.hpp" +#include "../../ScriptTypes/ScriptType.hpp" #include "EvalValue.hpp" #include "../../Binder/BoundStatements/BoundStatement.hpp" #include "../EvaluationScope/EvaluationScope.hpp" -#include "../../FunctionScriptType.hpp" +#include "../../ScriptTypes/FunctionScriptType.hpp" using namespace std; diff --git a/src/Evaluator/Evaluator.cpp b/src/Evaluator/Evaluator.cpp index 8c8ee40..9e9dbe3 100644 --- a/src/Evaluator/Evaluator.cpp +++ b/src/Evaluator/Evaluator.cpp @@ -7,7 +7,7 @@ #include "EvalValues/TableEvalValue.hpp" #include "../Binder/BoundExpressions/BoundTableExpression.hpp" #include "../Binder/BoundExpressions/BoundFunctionCallExpression.hpp" -#include "../TableScriptType.hpp" +#include "../ScriptTypes/TableScriptType.hpp" #include "../UserData/UserDataFunction.hpp" #include "EvalValues/NumericalTableEvalValue.hpp" diff --git a/src/FunctionScriptType.cpp b/src/ScriptTypes/FunctionScriptType.cpp similarity index 100% rename from src/FunctionScriptType.cpp rename to src/ScriptTypes/FunctionScriptType.cpp diff --git a/src/FunctionScriptType.hpp b/src/ScriptTypes/FunctionScriptType.hpp similarity index 100% rename from src/FunctionScriptType.hpp rename to src/ScriptTypes/FunctionScriptType.hpp diff --git a/src/ScriptType.cpp b/src/ScriptTypes/ScriptType.cpp similarity index 95% rename from src/ScriptType.cpp rename to src/ScriptTypes/ScriptType.cpp index b2d2fc1..c4cc8f7 100644 --- a/src/ScriptType.cpp +++ b/src/ScriptTypes/ScriptType.cpp @@ -1,5 +1,5 @@ -#include "Script.hpp" -#include "UserData/UserDataFunctionType.hpp" +#include "../Script.hpp" +#include "../UserData/UserDataFunctionType.hpp" namespace Porygon{ inline bool ScriptType::CanBeIndexedWith(const ScriptType *) const{ diff --git a/src/ScriptType.hpp b/src/ScriptTypes/ScriptType.hpp similarity index 97% rename from src/ScriptType.hpp rename to src/ScriptTypes/ScriptType.hpp index 9a283ce..5cfa177 100644 --- a/src/ScriptType.hpp +++ b/src/ScriptTypes/ScriptType.hpp @@ -7,8 +7,8 @@ #include #include #include -#include "Binder/BoundVariables/BoundVariableKey.hpp" -#include "Utilities/HashedString.hpp" +#include "../Binder/BoundVariables/BoundVariableKey.hpp" +#include "../Utilities/HashedString.hpp" using namespace std; diff --git a/src/TableScriptType.hpp b/src/ScriptTypes/TableScriptType.hpp similarity index 97% rename from src/TableScriptType.hpp rename to src/ScriptTypes/TableScriptType.hpp index 0af352b..b996653 100644 --- a/src/TableScriptType.hpp +++ b/src/ScriptTypes/TableScriptType.hpp @@ -2,7 +2,7 @@ #ifndef PORYGONLANG_TABLESCRIPTTYPE_HPP #define PORYGONLANG_TABLESCRIPTTYPE_HPP #include -#include "Binder/BoundVariables/BoundVariable.hpp" +#include "../Binder/BoundVariables/BoundVariable.hpp" namespace Porygon{ class TableScriptType : public ScriptType{ diff --git a/src/UserData/UserDataFunction.hpp b/src/UserData/UserDataFunction.hpp index 027f93e..45b8d9e 100644 --- a/src/UserData/UserDataFunction.hpp +++ b/src/UserData/UserDataFunction.hpp @@ -3,7 +3,7 @@ #include "../Evaluator/EvalValues/ScriptFunctionEvalValue.hpp" #include "UserDataFunctionType.hpp" -#include "../FunctionScriptType.hpp" +#include "../ScriptTypes/FunctionScriptType.hpp" namespace Porygon::UserData{ class UserDataFunction : public Evaluation::GenericFunctionOption { diff --git a/src/UserData/UserDataFunctionType.hpp b/src/UserData/UserDataFunctionType.hpp index 4ade87a..b3060dd 100644 --- a/src/UserData/UserDataFunctionType.hpp +++ b/src/UserData/UserDataFunctionType.hpp @@ -2,8 +2,8 @@ #define PORYGONLANG_USERDATAFUNCTIONTYPE_HPP #include -#include "../ScriptType.hpp" -#include "../FunctionScriptType.hpp" +#include "../ScriptTypes/ScriptType.hpp" +#include "../ScriptTypes/FunctionScriptType.hpp" namespace Porygon::UserData{ class UserDataFunctionOption : public GenericFunctionOption{ diff --git a/src/UserData/UserDataScriptType.hpp b/src/UserData/UserDataScriptType.hpp index d829369..7b043fa 100644 --- a/src/UserData/UserDataScriptType.hpp +++ b/src/UserData/UserDataScriptType.hpp @@ -4,7 +4,7 @@ #define PORYGONLANG_USERDATASCRIPTTYPE_HPP #include -#include "../ScriptType.hpp" +#include "../ScriptTypes/ScriptType.hpp" #include "UserData.hpp" #include "UserDataStorage.hpp"