aul::ast::FunctionDecl Class Referenceabstract

#include <C4AulAST.h>

Inheritance diagram for aul::ast::FunctionDecl:
Collaboration diagram for aul::ast::FunctionDecl:

Public Member Functions

 FunctionDecl (const std::string &name)
virtual bool has_value () const
virtual void accept (::aul::AstVisitor *) const =0
virtual void accept (::aul::AstVisitor *v) const =0

Public Attributes

std::string name
bool is_global = false
const char * loc = nullptr
std::vector< Parameterparams
bool has_unnamed_params = false
std::unique_ptr< Blockbody

Detailed Description

Definition at line 385 of file C4AulAST.h.

Constructor & Destructor Documentation

◆ FunctionDecl()

aul::ast::FunctionDecl::FunctionDecl ( const std::string &  name)

Definition at line 389 of file C4AulAST.h.

389 : name(name) {}
std::string name
Definition: C4AulAST.h:390

Member Function Documentation

◆ accept() [1/2]

virtual void aul::ast::Node::accept ( ::aul::AstVisitor ) const
pure virtualinherited

◆ accept() [2/2]

virtual void aul::ast::Function::accept ( ::aul::AstVisitor v) const
pure virtualinherited

◆ has_value()

virtual bool aul::ast::Stmt::has_value ( ) const

Reimplemented in aul::ast::Expr.

Definition at line 132 of file C4AulAST.h.

132 { return false; }

Member Data Documentation

◆ body

std::unique_ptr<Block> aul::ast::Function::body

Definition at line 379 of file C4AulAST.h.

◆ has_unnamed_params

bool aul::ast::Function::has_unnamed_params = false

Definition at line 378 of file C4AulAST.h.

◆ is_global

bool aul::ast::FunctionDecl::is_global = false

Definition at line 391 of file C4AulAST.h.

◆ loc

const char* aul::ast::Node::loc = nullptr

Definition at line 123 of file C4AulAST.h.

◆ name

std::string aul::ast::FunctionDecl::name

Definition at line 390 of file C4AulAST.h.

◆ params

std::vector<Parameter> aul::ast::Function::params

Definition at line 377 of file C4AulAST.h.

The documentation for this class was generated from the following file: