mirror of
https://github.com/polserver/polserver
synced 2026-08-13 08:23:08 -04:00
* all except pol * pol and includes under defines * something weird has happened * remove own folder from include searchpath * fixed remaining, adapted include style for external headers * missing include
29 lines
711 B
C++
29 lines
711 B
C++
#include "bscript/compiler/ast/SequenceBinding.h"
|
|
|
|
#include "bscript/compiler/ast/Node.h"
|
|
#include "bscript/compiler/ast/NodeVisitor.h"
|
|
#include "clib/clib.h"
|
|
|
|
namespace Pol::Bscript::Compiler
|
|
{
|
|
SequenceBinding::SequenceBinding( const SourceLocation& loc,
|
|
std::vector<std::unique_ptr<Node>> bindings )
|
|
: Node( loc, std::move( bindings ) )
|
|
{
|
|
}
|
|
u8 SequenceBinding::binding_count() const
|
|
{
|
|
return Clib::clamp_convert<u8>( children.size() );
|
|
}
|
|
|
|
void SequenceBinding::accept( NodeVisitor& visitor )
|
|
{
|
|
visitor.visit_sequence_binding( *this );
|
|
}
|
|
|
|
void SequenceBinding::describe_to( std::string& w ) const
|
|
{
|
|
w += "sequence-binding";
|
|
}
|
|
|
|
} // namespace Pol::Bscript::Compiler
|