From 5451604f8b701db7de7f0489ad50d680fb732151 Mon Sep 17 00:00:00 2001 From: Fly Lang Date: Sun, 28 Apr 2024 16:29:50 +0200 Subject: [PATCH] Replace ASTParams with llvm::SmallVector of ASTParam --- include/AST/ASTContext.h | 2 -- include/AST/ASTFunction.h | 3 --- include/AST/ASTFunctionBase.h | 16 ++++++------ include/AST/{ASTParams.h => ASTParam.h} | 33 +++---------------------- include/CodeGen/CodeGenFunctionBase.h | 5 ++-- include/Sema/SemaBuilder.h | 14 +++++------ include/Sema/SemaValidator.h | 11 ++++----- src/AST/ASTFunctionBase.cpp | 25 ++++++++++--------- src/AST/{ASTParams.cpp => ASTParam.cpp} | 30 ++-------------------- src/CMakeLists.txt | 2 +- src/CodeGen/CodeGenClassFunction.cpp | 2 +- src/CodeGen/CodeGenFunction.cpp | 2 +- src/CodeGen/CodeGenFunctionBase.cpp | 20 +++++++-------- src/CodeGen/CodeGenHeader.cpp | 6 ++--- src/Parser/FunctionParser.cpp | 2 +- src/Sema/Sema.cpp | 8 +++--- src/Sema/SemaBuilder.cpp | 2 +- src/Sema/SemaResolver.cpp | 8 +++--- src/Sema/SemaValidator.cpp | 6 ++--- test/CodeGenTest.cpp | 2 +- test/ParserBadCode.cpp | 2 +- test/ParserBlockTest.cpp | 2 +- test/ParserExprTest.cpp | 2 +- test/ParserTest.cpp | 2 +- 24 files changed, 75 insertions(+), 132 deletions(-) rename include/AST/{ASTParams.h => ASTParam.h} (62%) rename src/AST/{ASTParams.cpp => ASTParam.cpp} (61%) diff --git a/include/AST/ASTContext.h b/include/AST/ASTContext.h index 218b2ab65..0f211ed8c 100644 --- a/include/AST/ASTContext.h +++ b/include/AST/ASTContext.h @@ -12,8 +12,6 @@ #include "llvm/ADT/StringMap.h" -#include - namespace fly { class SourceLocation; diff --git a/include/AST/ASTFunction.h b/include/AST/ASTFunction.h index 6b2dd7775..cebcc8c42 100644 --- a/include/AST/ASTFunction.h +++ b/include/AST/ASTFunction.h @@ -14,12 +14,9 @@ #include "ASTFunctionBase.h" #include "CodeGen/CodeGenFunction.h" -#include - namespace fly { class ASTNode; - class ASTParams; class ASTType; class ASTBlock; class ASTScopes; diff --git a/include/AST/ASTFunctionBase.h b/include/AST/ASTFunctionBase.h index 834970fad..e87301d96 100644 --- a/include/AST/ASTFunctionBase.h +++ b/include/AST/ASTFunctionBase.h @@ -13,12 +13,9 @@ #include "ASTStmt.h" #include "ASTBase.h" -#include - namespace fly { class ASTGroupExpr; - class ASTParams; class ASTExpr; class ASTType; class ASTVarRef; @@ -57,8 +54,9 @@ namespace fly { ASTScopes * Scopes; - // Header contains parameters - ASTParams *Params = nullptr; + llvm::SmallVector Params; + + ASTParam* Ellipsis = nullptr; // Body is the main BlockStmt ASTBlock *Body = nullptr; @@ -82,9 +80,11 @@ namespace fly { void addParam(ASTParam *Param); - void setEllipsis(ASTParam *Param); + llvm::SmallVector getParams() const; - const ASTParams *getParams() const; + ASTParam *getEllipsis() const; + + void setEllipsis(ASTParam *Param); const ASTBlock *getBody() const; @@ -120,7 +120,7 @@ namespace fly { ASTBlock *getBlock() const; - std::string str() const; + std::string str() const override; }; } diff --git a/include/AST/ASTParams.h b/include/AST/ASTParam.h similarity index 62% rename from include/AST/ASTParams.h rename to include/AST/ASTParam.h index 794b41395..b8309926c 100644 --- a/include/AST/ASTParams.h +++ b/include/AST/ASTParam.h @@ -7,8 +7,8 @@ // //===--------------------------------------------------------------------------------------------------------------===// -#ifndef FLY_ASTPARAMS_H -#define FLY_ASTPARAMS_H +#ifndef FLY_ASTPARAM_H +#define FLY_ASTPARAM_H #include "ASTLocalVar.h" @@ -39,33 +39,6 @@ namespace fly { std::string str() const override; }; - - /** - * All Parameters of a Function for Definition - * Ex. - * func(int param1, float param2, bool param3, ...) - */ - class ASTParams { - - friend class ASTFunctionBase; - - llvm::SmallVector List; - - ASTParam* Ellipsis = nullptr; - - public: - uint64_t getSize() const; - - ASTParam *at(unsigned long Index) const; - - bool isEmpty() const; - - const llvm::SmallVector &getList() const; - - const ASTParam* getEllipsis() const; - - std::string str() const; - }; } -#endif //FLY_ASTPARAMS_H +#endif //FLY_ASTPARAM_H diff --git a/include/CodeGen/CodeGenFunctionBase.h b/include/CodeGen/CodeGenFunctionBase.h index 95f9c0680..fac8e75db 100644 --- a/include/CodeGen/CodeGenFunctionBase.h +++ b/include/CodeGen/CodeGenFunctionBase.h @@ -13,7 +13,7 @@ #include "llvm/ADT/StringRef.h" #include "llvm/ADT/SmallVector.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" namespace llvm { class Function; @@ -26,7 +26,6 @@ namespace llvm { namespace fly { class ASTFunctionBase; - class ASTParams; class ASTType; class CodeGenModule; @@ -56,7 +55,7 @@ namespace fly { void GenReturnType(); - void GenParamTypes(CodeGenModule * CGM, SmallVector &Types, const ASTParams *Params); + void GenParamTypes(CodeGenModule * CGM, SmallVector &Types, llvm::SmallVector Params); ASTFunctionBase *getAST(); diff --git a/include/Sema/SemaBuilder.h b/include/Sema/SemaBuilder.h index 9f3f7ee52..61f90ff7a 100644 --- a/include/Sema/SemaBuilder.h +++ b/include/Sema/SemaBuilder.h @@ -462,14 +462,14 @@ namespace fly { if (StrMapIt != Functions.end()) { // Search by Number of Parameters - const auto IntMapIt = StrMapIt->second.find(NewFunction->Params->getSize()); + const auto IntMapIt = StrMapIt->second.find(NewFunction->getParams().size()); // Search by Type of Parameters llvm::SmallVector VectorFunctions = IntMapIt->second; for (auto &Function: VectorFunctions) { // Check if NewFunction have no params - if (NewFunction->getParams()->isEmpty() && Function->getParams()->isEmpty()) { + if (NewFunction->getParams().empty() && Function->getParams().empty()) { return true; } @@ -496,7 +496,7 @@ namespace fly { // add to std::map std::map> IntMap; - IntMap.insert(std::make_pair(NewFunction->Params->getSize(), Vect)); + IntMap.insert(std::make_pair(NewFunction->getParams().size(), Vect)); // add to llvm::StringMap return Functions.insert(std::make_pair(NewFunction->getName(), IntMap)).second; @@ -509,7 +509,7 @@ namespace fly { bool InsertFunction(std::map> &Functions, T *NewFunction) { // This Node contains a Function with this Function->Name - const auto &IntMapIt = Functions.find(NewFunction->Params->getSize()); + const auto &IntMapIt = Functions.find(NewFunction->getParams().size()); if (IntMapIt == Functions.end()) { // but not have the same number of Params // add to llvm::SmallVector @@ -518,15 +518,15 @@ namespace fly { // add to std::map std::pair> IntMapPair = std::make_pair( - NewFunction->Params->getSize(), VectorFunctions); + NewFunction->getParams().size(), VectorFunctions); - return Functions.insert(std::make_pair(NewFunction->Params->getSize(), VectorFunctions)).second; + return Functions.insert(std::make_pair(NewFunction->getParams().size(), VectorFunctions)).second; } else { // This Node contains a Function with this Function->Name and same number of Params llvm::SmallVector VectorFunctions = IntMapIt->second; for (auto &Function: VectorFunctions) { // check no params duplicates - if (NewFunction->getParams()->isEmpty() && Function->getParams()->isEmpty()) { + if (NewFunction->getParams().empty() && Function->getParams().empty()) { // Error: return false; } diff --git a/include/Sema/SemaValidator.h b/include/Sema/SemaValidator.h index d31097cfe..9e73d1a9a 100644 --- a/include/Sema/SemaValidator.h +++ b/include/Sema/SemaValidator.h @@ -11,7 +11,7 @@ #define FLY_SEMA_VALIDATOR_H #include "AST/ASTType.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" #include "AST/ASTClassType.h" namespace fly { @@ -25,7 +25,6 @@ namespace fly { class ASTNode; class ASTImport; class ASTExpr; - class ASTParams; class ASTParam; class ASTType; class SourceLocation; @@ -42,14 +41,14 @@ namespace fly { bool DiagEnabled = true; - bool CheckDuplicateParams(ASTParams *Params, ASTParam *Param); + bool CheckDuplicateParams(llvm::SmallVector Params, ASTParam *Param); bool CheckDuplicateLocalVars(ASTStmt *Stmt, llvm::StringRef VarName); - static bool CheckParams(const ASTParams *Params, const ASTParams *CheckParams) { + static bool CheckParams(llvm::SmallVector Params, llvm::SmallVector CheckParams) { // Types will be checked on Resolve() - for (ASTParam *Param : Params->getList()) { - for (ASTParam *CheckParam: CheckParams->getList()) { + for (ASTParam *Param : Params) { + for (ASTParam *CheckParam : CheckParams) { if (CheckEqualTypes(Param->getType(), CheckParam->getType())) { return false; } diff --git a/src/AST/ASTFunctionBase.cpp b/src/AST/ASTFunctionBase.cpp index 10258356e..361c4b792 100644 --- a/src/AST/ASTFunctionBase.cpp +++ b/src/AST/ASTFunctionBase.cpp @@ -9,14 +9,13 @@ #include "AST/ASTFunctionBase.h" #include "AST/ASTBlock.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" using namespace fly; ASTFunctionBase::ASTFunctionBase(const SourceLocation &Loc, ASTFunctionKind Kind, ASTType *ReturnType, llvm::StringRef Name, ASTScopes * Scopes) : - ASTBase(Loc), Kind(Kind), ReturnType(ReturnType), - Params(new ASTParams()), Name(Name), Scopes(Scopes) { + ASTBase(Loc), Kind(Kind), ReturnType(ReturnType), Name(Name), Scopes(Scopes) { } @@ -29,11 +28,15 @@ ASTScopes *ASTFunctionBase::getScopes() const { } void ASTFunctionBase::addParam(ASTParam *Param) { - Params->List.push_back(Param); + Params.push_back(Param); +} + +llvm::SmallVector ASTFunctionBase::getParams() const { + return Params; } void ASTFunctionBase::setEllipsis(ASTParam *Param) { - Params->Ellipsis = Param; + Ellipsis = Param; } const ASTBlock *ASTFunctionBase::getBody() const { @@ -48,10 +51,6 @@ ASTParam *ASTFunctionBase::getErrorHandler() { return ErrorHandler; } -const ASTParams *ASTFunctionBase::getParams() const { - return Params; -} - ASTFunctionKind ASTFunctionBase::getKind() { return Kind; } @@ -61,18 +60,22 @@ ASTType *ASTFunctionBase::getType() const { } bool ASTFunctionBase::isVarArg() { - return Params->getEllipsis(); + return Ellipsis != nullptr; } std::string ASTFunctionBase::str() const { return Logger("ASTFunctionBase"). Super(ASTBase::str()). Attr("Name", Name). - Attr("Params", Params). + AttrList("Params", Params). Attr("ReturnType", ReturnType). End(); } +ASTParam *ASTFunctionBase::getEllipsis() const { + return Ellipsis; +} + ASTReturnStmt::ASTReturnStmt(ASTBlock *Parent, const SourceLocation &Loc) : ASTStmt(Parent, Loc, ASTStmtKind::STMT_RETURN) { diff --git a/src/AST/ASTParams.cpp b/src/AST/ASTParam.cpp similarity index 61% rename from src/AST/ASTParams.cpp rename to src/AST/ASTParam.cpp index 5bf38bf63..54426beca 100644 --- a/src/AST/ASTParams.cpp +++ b/src/AST/ASTParam.cpp @@ -1,5 +1,5 @@ //===--------------------------------------------------------------------------------------------------------------===// -// src/AST/ASTParams.cpp - AST Params implementation +// src/AST/ASTParam.cpp - AST Param implementation // // Part of the Fly Project https://flylang.org // Under the Apache License v2.0 see LICENSE for details. @@ -7,7 +7,7 @@ // //===--------------------------------------------------------------------------------------------------------------===// -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" using namespace fly; @@ -33,29 +33,3 @@ std::string ASTParam::str() const { Super(ASTLocalVar::str()). End(); } - -uint64_t ASTParams::getSize() const { - return List.size(); -} - -ASTParam *ASTParams::at(unsigned long Index) const { - return List[Index]; -} - -bool ASTParams::isEmpty() const { - return List.empty() && Ellipsis == nullptr; -} - -const llvm::SmallVector &ASTParams::getList() const { - return List; -} - -const ASTParam *ASTParams::getEllipsis() const { - return Ellipsis; -} - -std::string ASTParams::str() const { - return Logger("ASTParams"). - AttrList("List", List). - End(); -} diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index a54456115..01aea0118 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -32,7 +32,7 @@ add_library(flyLib AST/ASTLocalVar.cpp AST/ASTNameSpace.cpp AST/ASTNode.cpp - AST/ASTParams.cpp + AST/ASTParam.cpp AST/ASTScopes.cpp AST/ASTStmt.cpp AST/ASTSwitchBlock.cpp diff --git a/src/CodeGen/CodeGenClassFunction.cpp b/src/CodeGen/CodeGenClassFunction.cpp index afbed749f..3a27ac18d 100644 --- a/src/CodeGen/CodeGenClassFunction.cpp +++ b/src/CodeGen/CodeGenClassFunction.cpp @@ -37,7 +37,7 @@ CodeGenClassFunction::CodeGenClassFunction(CodeGenModule *CGM, ASTClassFunction GenParamTypes(CGM, ParamTypes, AST->getParams()); // Set LLVM Function Name %MODULE_CLASS_METHOD (if MODULE == default is empty) - FnType = llvm::FunctionType::get(RetType, ParamTypes, AST->getParams()->getEllipsis() != nullptr); + FnType = llvm::FunctionType::get(RetType, ParamTypes, AST->getEllipsis() != nullptr); std::string Name = CodeGen::toIdentifier(getAST()->getName(), Class->getNameSpace()->getName(), Class->getName()); Fn = llvm::Function::Create(FnType, llvm::GlobalValue::ExternalLinkage, Name, CGM->getModule()); diff --git a/src/CodeGen/CodeGenFunction.cpp b/src/CodeGen/CodeGenFunction.cpp index ecbf5a2f9..a238d2aae 100644 --- a/src/CodeGen/CodeGenFunction.cpp +++ b/src/CodeGen/CodeGenFunction.cpp @@ -38,7 +38,7 @@ CodeGenFunction::CodeGenFunction(CodeGenModule *CGM, ASTFunction *AST, bool isEx GenParamTypes(CGM, ParamTypes, AST->getParams()); // Create LLVM Function - FnType = llvm::FunctionType::get(RetType, ParamTypes, AST->getParams()->getEllipsis() != nullptr); + FnType = llvm::FunctionType::get(RetType, ParamTypes, AST->getEllipsis() != nullptr); Fn = llvm::Function::Create(FnType, llvm::GlobalValue::ExternalLinkage, "", CGM->getModule()); // Set Name diff --git a/src/CodeGen/CodeGenFunctionBase.cpp b/src/CodeGen/CodeGenFunctionBase.cpp index 8f4be4574..a58e6aa5b 100644 --- a/src/CodeGen/CodeGenFunctionBase.cpp +++ b/src/CodeGen/CodeGenFunctionBase.cpp @@ -15,7 +15,7 @@ #include "CodeGen/CodeGenError.h" #include "AST/ASTNameSpace.h" #include "AST/ASTFunction.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" #include "AST/ASTCall.h" #include "AST/ASTType.h" #include "AST/ASTIdentityType.h" @@ -40,20 +40,20 @@ void CodeGenFunctionBase::GenReturnType() { RetType = CGM->GenType(AST->getType()); } -void CodeGenFunctionBase::GenParamTypes(CodeGenModule * CGM, llvm::SmallVector &Types, const ASTParams *Params) { +void CodeGenFunctionBase::GenParamTypes(CodeGenModule * CGM, llvm::SmallVector &Types, llvm::SmallVector Params) { // Populate Types by reference - if (Params->isEmpty()) { + if (Params.empty()) { return; } - if (!Params->getList().empty()) { - for (auto Param : Params->getList()) { + if (!Params.empty()) { + for (auto Param : Params) { llvm::Type *ParamTy = CGM->GenType(Param->getType()); Types.push_back(ParamTy); } } - if (Params->getEllipsis() != nullptr) { +// if (Params->getEllipsis() != nullptr) { // TODO - } +// } } ASTFunctionBase *CodeGenFunctionBase::getAST() { @@ -80,8 +80,8 @@ void CodeGenFunctionBase::setInsertPoint() { void CodeGenFunctionBase::AllocaVars() { - // Allocation of declared ASTParams - for (auto &Param: AST->getParams()->getList()) { + // Allocation of declared ASTParam + for (auto &Param: AST->getParams()) { Param->setCodeGen(CGM->GenVar(Param)); Param->getCodeGen()->Init(); } @@ -98,7 +98,7 @@ void CodeGenFunctionBase::StoreParams(bool isMain) { // Store Param Values (n = 0 is the Error param) int n = isMain ? 0 : 1; - for (auto &Param: AST->getParams()->getList()) { + for (auto &Param: AST->getParams()) { // Store Arg value into Param CodeGenVarBase *CGV = Param->getCodeGen(); diff --git a/src/CodeGen/CodeGenHeader.cpp b/src/CodeGen/CodeGenHeader.cpp index aa7e356a8..852b89f7a 100644 --- a/src/CodeGen/CodeGenHeader.cpp +++ b/src/CodeGen/CodeGenHeader.cpp @@ -12,7 +12,7 @@ #include "AST/ASTType.h" #include "AST/ASTGlobalVar.h" #include "AST/ASTFunction.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" #include "AST/ASTScopes.h" #include "Basic/Diagnostic.h" #include "Basic/CodeGenOptions.h" @@ -57,9 +57,9 @@ std::string CodeGenHeader::GenerateFile() { Header += "\npublic " + Convert(Function->getType()) + " " + std::string(Function->getName()) + "("; int i = 0; - for (auto &Param : Function->getParams()->getList()) { + for (auto &Param : Function->getParams()) { Header += Convert(Param->getType()) + " " + std::string(Param->getName()); - if (i < Function->getParams()->getList().size()) { + if (i < Function->getParams().size()) { Header += ","; } } diff --git a/src/Parser/FunctionParser.cpp b/src/Parser/FunctionParser.cpp index a02f16c8b..156263ea4 100644 --- a/src/Parser/FunctionParser.cpp +++ b/src/Parser/FunctionParser.cpp @@ -9,7 +9,7 @@ #include "Parser/Parser.h" #include "Parser/FunctionParser.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" #include "AST/ASTFunction.h" #include "AST/ASTCall.h" #include "AST/ASTExpr.h" diff --git a/src/Sema/Sema.cpp b/src/Sema/Sema.cpp index 16d357772..f653d7067 100644 --- a/src/Sema/Sema.cpp +++ b/src/Sema/Sema.cpp @@ -24,7 +24,7 @@ #include "AST/ASTClassFunction.h" #include "AST/ASTNode.h" #include "AST/ASTVarRef.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" #include "Basic/Diagnostic.h" #include "Basic/SourceLocation.h" #include "AST/ASTBase.h" @@ -112,9 +112,9 @@ ASTVar *Sema::FindLocalVar(ASTBlock *Block, llvm::StringRef Name) const { if (Block->Parent->getKind() == ASTStmtKind::STMT_BLOCK) return FindLocalVar((ASTBlock *) Block->getParent(), Name); } else { - const ASTParams *Params = Block->getTop()->getParams(); - for (auto &Param : Params->getList()) { - if (Param->getName() == Name) { // Search into ASTParams + llvm::SmallVector Params = Block->getTop()->getParams(); + for (auto &Param : Params) { + if (Param->getName() == Name) { // Search into ASTParam list return Param; } } diff --git a/src/Sema/SemaBuilder.cpp b/src/Sema/SemaBuilder.cpp index 92503325f..f35fa47f8 100644 --- a/src/Sema/SemaBuilder.cpp +++ b/src/Sema/SemaBuilder.cpp @@ -22,7 +22,7 @@ #include "AST/ASTFunctionBase.h" #include "AST/ASTCall.h" #include "AST/ASTDeleteStmt.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" #include "AST/ASTBlock.h" #include "AST/ASTIfBlock.h" #include "AST/ASTWhileBlock.h" diff --git a/src/Sema/SemaResolver.cpp b/src/Sema/SemaResolver.cpp index 32fc933d7..b2a3b27f1 100644 --- a/src/Sema/SemaResolver.cpp +++ b/src/Sema/SemaResolver.cpp @@ -25,7 +25,7 @@ #include "AST/ASTFunction.h" #include "AST/ASTCall.h" #include "AST/ASTIdentifier.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" #include "AST/ASTSwitchBlock.h" #include "AST/ASTForBlock.h" #include "AST/ASTWhileBlock.h" @@ -783,15 +783,15 @@ bool SemaResolver::ResolveCall(ASTBlock *Block, ASTCall *Call, if (IntMapIt != Functions.end()) { // Map contains Function with this size of args S.Validator->DiagEnabled = false; for (T *Function : IntMapIt->second) { - if (Function->getParams()->getSize() == Call->getArgs().size()) { + if (Function->getParams().size() == Call->getArgs().size()) { bool Success = true; // if Params = Args = 0 skip for cycle if (Call->getArgs().empty()) { // call function with no parameters Success = true; } else { - for (unsigned long i = 0; i < Function->getParams()->getSize(); i++) { + for (unsigned long i = 0; i < Function->getParams().size(); i++) { // Resolve Arg Expr on first ASTArg *Arg = Call->getArgs()[i]; - ASTParam *Param = Function->getParams()->at(i); + ASTParam *Param = Function->getParams()[i]; Success &= ResolveArg(Block, Arg, Param); } } diff --git a/src/Sema/SemaValidator.cpp b/src/Sema/SemaValidator.cpp index 5435dfa37..200123f38 100644 --- a/src/Sema/SemaValidator.cpp +++ b/src/Sema/SemaValidator.cpp @@ -16,7 +16,7 @@ #include "AST/ASTClass.h" #include "AST/ASTGlobalVar.h" #include "AST/ASTFunctionBase.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" #include "AST/ASTBlock.h" #include "AST/ASTVarRef.h" #include "Basic/Diagnostic.h" @@ -33,8 +33,8 @@ SemaValidator::SemaValidator(Sema &S) : S(S) { * @param Param * @return */ -bool SemaValidator::CheckDuplicateParams(ASTParams *Params, ASTParam *Param) { - for (ASTParam *P : Params->getList()) { +bool SemaValidator::CheckDuplicateParams(llvm::SmallVector Params, ASTParam *Param) { + for (ASTParam *P : Params) { if (P->getName() == Param->getName()) { if (DiagEnabled) S.Diag(Param->getLocation(), diag::err_conflict_params) << Param->getName(); diff --git a/test/CodeGenTest.cpp b/test/CodeGenTest.cpp index f3fbd330c..c7220934a 100644 --- a/test/CodeGenTest.cpp +++ b/test/CodeGenTest.cpp @@ -29,7 +29,7 @@ #include "AST/ASTVarStmt.h" #include "AST/ASTValue.h" #include "AST/ASTLocalVar.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" #include "AST/ASTIfBlock.h" #include "AST/ASTSwitchBlock.h" #include "AST/ASTWhileBlock.h" diff --git a/test/ParserBadCode.cpp b/test/ParserBadCode.cpp index ff0f241e2..24e2ef20b 100644 --- a/test/ParserBadCode.cpp +++ b/test/ParserBadCode.cpp @@ -18,7 +18,7 @@ #include "AST/ASTValue.h" #include "AST/ASTVarStmt.h" #include "AST/ASTVarRef.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" #include "AST/ASTWhileBlock.h" #include "AST/ASTIfBlock.h" #include "AST/ASTSwitchBlock.h" diff --git a/test/ParserBlockTest.cpp b/test/ParserBlockTest.cpp index 34d8e742e..4fc7b0a64 100644 --- a/test/ParserBlockTest.cpp +++ b/test/ParserBlockTest.cpp @@ -18,7 +18,7 @@ #include "AST/ASTValue.h" #include "AST/ASTVarStmt.h" #include "AST/ASTVarRef.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" #include "AST/ASTWhileBlock.h" #include "AST/ASTIfBlock.h" #include "AST/ASTSwitchBlock.h" diff --git a/test/ParserExprTest.cpp b/test/ParserExprTest.cpp index 6077ba8f9..12171b4a3 100644 --- a/test/ParserExprTest.cpp +++ b/test/ParserExprTest.cpp @@ -18,7 +18,7 @@ #include "AST/ASTValue.h" #include "AST/ASTVarStmt.h" #include "AST/ASTVarRef.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" #include "AST/ASTWhileBlock.h" #include "AST/ASTIfBlock.h" #include "AST/ASTSwitchBlock.h" diff --git a/test/ParserTest.cpp b/test/ParserTest.cpp index febcf4458..28ca04f9c 100644 --- a/test/ParserTest.cpp +++ b/test/ParserTest.cpp @@ -18,7 +18,7 @@ #include "AST/ASTValue.h" #include "AST/ASTVarStmt.h" #include "AST/ASTVarRef.h" -#include "AST/ASTParams.h" +#include "AST/ASTParam.h" #include "AST/ASTWhileBlock.h" #include "AST/ASTIfBlock.h" #include "AST/ASTSwitchBlock.h"