mirror of
https://github.com/polserver/polserver
synced 2026-08-13 08:23:08 -04:00
Adds enough to build the AST nodes for the module function declarations in a .em file. Adds: - Function: base class for module function declarations and user functions - FunctionParameterDeclaration: declaration for a function parameter, as well as its default value if any - FunctionParameterList: just a holder for function parameter declarations - ModuleFunctionDeclaration: for function declarations in .em files - FunctionResolver: hooks up function calls to module functions or user functions - ModuleProcessor: a visitor for processing const declarations and module function declarations (const declarations are yet to come from the main branch)
24 lines
741 B
C++
24 lines
741 B
C++
#include "BuilderWorkspace.h"
|
|
|
|
#include "compiler/file/SourceFile.h"
|
|
#include "compiler/file/SourceFileCache.h"
|
|
#include "compiler/ast/Statement.h"
|
|
#include "compiler/file/SourceFileIdentifier.h"
|
|
|
|
namespace Pol::Bscript::Compiler
|
|
{
|
|
BuilderWorkspace::BuilderWorkspace( CompilerWorkspace& compiler_workspace,
|
|
SourceFileCache& em_cache, SourceFileCache& inc_cache,
|
|
Profile& profile, Report& report )
|
|
: compiler_workspace( compiler_workspace ),
|
|
em_cache( em_cache ),
|
|
inc_cache( inc_cache ),
|
|
profile( profile ),
|
|
report( report ),
|
|
function_resolver( report )
|
|
{
|
|
}
|
|
|
|
BuilderWorkspace::~BuilderWorkspace() = default;
|
|
|
|
} // namespace Pol::Bscript::Compiler
|