1 #ifndef STAN_LANG_AST_NODE_STATEMENT_HPP 2 #define STAN_LANG_AST_NODE_STATEMENT_HPP 4 #include <boost/variant/recursive_variant.hpp> 14 struct increment_log_prob_statement;
18 struct conditional_statement;
19 struct while_statement;
20 struct break_continue_statement;
21 struct print_statement;
22 struct reject_statement;
23 struct return_statement;
24 struct no_op_statement;
33 typedef boost::variant<boost::recursive_wrapper<nil>,
34 boost::recursive_wrapper<assignment>,
35 boost::recursive_wrapper<assgn>,
36 boost::recursive_wrapper<sample>,
37 boost::recursive_wrapper<increment_log_prob_statement>,
38 boost::recursive_wrapper<expression>,
39 boost::recursive_wrapper<statements>,
40 boost::recursive_wrapper<for_statement>,
41 boost::recursive_wrapper<conditional_statement>,
42 boost::recursive_wrapper<while_statement>,
43 boost::recursive_wrapper<break_continue_statement>,
44 boost::recursive_wrapper<print_statement>,
45 boost::recursive_wrapper<reject_statement>,
46 boost::recursive_wrapper<return_statement>,
47 boost::recursive_wrapper<no_op_statement> >
AST node for print statements.
Structure to wrap the variant type of statements.
bool is_no_op_statement() const
Return true if the basic statement held by the variant type in this wrapper is the no-op statement...
Holder for local variable declarations and a sequence of statements.
AST node for assignment to variable with multi-indexing.
void sample(stan::mcmc::base_mcmc *sampler, int num_warmup, int num_samples, int num_thin, int refresh, bool save, stan::services::sample::mcmc_writer< Model, SampleRecorder, DiagnosticRecorder, MessageRecorder > &mcmc_writer, stan::mcmc::sample &init_s, Model &model, RNG &base_rng, const std::string &prefix, const std::string &suffix, std::ostream &o, StartTransitionCallback &callback, interface_callbacks::writer::base_writer &info_writer, interface_callbacks::writer::base_writer &error_writer)
AST node for the increment log prob (deprecated) and target increment statements. ...
Probability, optimization and sampling library.
AST node for the reject statement.
AST structure for break and continue statements.
statement_t statement_
The statement variant type held by this wrapper.
AST node for sampling statements.
statement()
Construct a default (nil) statement.
boost::variant< boost::recursive_wrapper< nil >, boost::recursive_wrapper< assignment >, boost::recursive_wrapper< assgn >, boost::recursive_wrapper< sample >, boost::recursive_wrapper< increment_log_prob_statement >, boost::recursive_wrapper< expression >, boost::recursive_wrapper< statements >, boost::recursive_wrapper< for_statement >, boost::recursive_wrapper< conditional_statement >, boost::recursive_wrapper< while_statement >, boost::recursive_wrapper< break_continue_statement >, boost::recursive_wrapper< print_statement >, boost::recursive_wrapper< reject_statement >, boost::recursive_wrapper< return_statement >, boost::recursive_wrapper< no_op_statement > > statement_t
The variant type of statements.
std::size_t begin_line_
The line in the source code where the statement begins.
AST node for representing while statements.
AST node for the no-operation statement.
AST node for the return statement.
std::size_t end_line_
The line in the source code where the statement ends.
The nil structure used as a placeholder for undefined or empty values in several structures.
AST node for representing a for statement.
AST node for conditional statements.
AST node for assignment statements.