2020-09-06 00:13:49 -07:00
|
|
|
#include "ArrayInitializer.h"
|
|
|
|
|
|
|
|
|
|
|
2021-02-25 16:53:22 +01:00
|
|
|
#include "bscript/compiler/ast/NodeVisitor.h"
|
2020-09-06 00:13:49 -07:00
|
|
|
|
|
|
|
|
namespace Pol::Bscript::Compiler
|
|
|
|
|
{
|
|
|
|
|
ArrayInitializer::ArrayInitializer( const SourceLocation& source_location,
|
|
|
|
|
std::vector<std::unique_ptr<Expression>> children )
|
|
|
|
|
: Expression( source_location, std::move( children ) )
|
|
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ArrayInitializer::accept( NodeVisitor& visitor )
|
|
|
|
|
{
|
|
|
|
|
visitor.visit_array_initializer( *this );
|
|
|
|
|
}
|
|
|
|
|
|
2024-01-12 06:51:44 +01:00
|
|
|
void ArrayInitializer::describe_to( std::string& w ) const
|
2020-09-06 00:13:49 -07:00
|
|
|
{
|
2024-01-12 06:51:44 +01:00
|
|
|
w += "array-initializer";
|
2020-09-06 00:13:49 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
} // namespace Pol::Bscript::Compiler
|