Stan  2.14.0
probability, sampling & optimization
var_decls_grammar.hpp
Go to the documentation of this file.
1 #ifndef STAN_LANG_GRAMMARS_VAR_DECLS_GRAMMAR_HPP
2 #define STAN_LANG_GRAMMARS_VAR_DECLS_GRAMMAR_HPP
3 
4 #include <stan/lang/ast.hpp>
9 #include <boost/spirit/include/qi.hpp>
10 #include <string>
11 #include <sstream>
12 #include <vector>
13 
14 namespace stan {
15  namespace lang {
16 
17  template <typename Iterator>
19  : boost::spirit::qi::grammar<Iterator,
20  boost::spirit::qi::locals<bool>,
21  std::vector<var_decl>(bool, var_origin),
22  whitespace_grammar<Iterator> > {
24  std::stringstream& error_msgs);
25 
27  std::stringstream& error_msgs_;
30 
31  boost::spirit::qi::rule<Iterator,
35 
36  boost::spirit::qi::rule<Iterator,
40 
41  boost::spirit::qi::rule<Iterator,
45 
46  boost::spirit::qi::rule<Iterator,
50 
51  boost::spirit::qi::rule<Iterator,
55 
56  boost::spirit::qi::rule<Iterator,
60 
61  boost::spirit::qi::rule<Iterator,
62  std::vector<expression>(var_origin),
65 
66  boost::spirit::qi::rule<Iterator,
70 
71  boost::spirit::qi::rule<Iterator,
75 
76  boost::spirit::qi::rule<Iterator,
77  std::string(),
80 
81  boost::spirit::qi::rule<Iterator,
82  std::string(),
85 
86  boost::spirit::qi::rule<Iterator,
90 
91  boost::spirit::qi::rule<Iterator,
95 
96 
97  boost::spirit::qi::rule<Iterator,
101 
102  boost::spirit::qi::rule<Iterator,
103  std::vector<expression>(var_origin),
106 
107  boost::spirit::qi::rule<Iterator,
111 
112  boost::spirit::qi::rule<Iterator,
116 
117  boost::spirit::qi::rule<Iterator,
118  range(var_origin),
121 
122  boost::spirit::qi::rule<Iterator,
123  range(var_origin),
126 
127  boost::spirit::qi::rule<Iterator,
131 
132  boost::spirit::qi::rule<Iterator,
136 
137  boost::spirit::qi::rule<Iterator,
141 
142  boost::spirit::qi::rule<Iterator,
146 
147  boost::spirit::qi::rule<Iterator,
148  boost::spirit::qi::locals<bool>,
149  var_decl(bool, var_origin),
152 
153  boost::spirit::qi::rule<Iterator,
154  boost::spirit::qi::locals<bool>,
155  std::vector<var_decl>(bool, var_origin),
158  };
159 
160  }
161 }
162 #endif
An integer variable declaration and optional definition.
Structure to hold the declaration of a positive ordered vector.
boost::spirit::qi::rule< Iterator, row_vector_var_decl(var_origin), whitespace_grammar< Iterator > > row_vector_decl_r
Structure to hold a row vector variable declaration.
boost::spirit::qi::rule< Iterator, std::string(), whitespace_grammar< Iterator > > identifier_name_r
boost::spirit::qi::rule< Iterator, ordered_var_decl(var_origin), whitespace_grammar< Iterator > > ordered_decl_r
Probability, optimization and sampling library.
boost::spirit::qi::rule< Iterator, positive_ordered_var_decl(var_origin), whitespace_grammar< Iterator > > positive_ordered_decl_r
expression_grammar< Iterator > expression_g
boost::spirit::qi::rule< Iterator, matrix_var_decl(var_origin), whitespace_grammar< Iterator > > matrix_decl_r
boost::spirit::qi::rule< Iterator, unit_vector_var_decl(var_origin), whitespace_grammar< Iterator > > unit_vector_decl_r
boost::spirit::qi::rule< Iterator, cholesky_corr_var_decl(var_origin), whitespace_grammar< Iterator > > cholesky_corr_decl_r
Structure to hold a covariance matrix variable declaration.
A map from function names to their base declarations and their origin.
boost::spirit::qi::rule< Iterator, std::string(), whitespace_grammar< Iterator > > identifier_r
Structure to hold the declaration of a simplex.
Structure to hold a Cholesky factor for a correlation matrix variable declaration.
boost::spirit::qi::rule< Iterator, cholesky_factor_var_decl(var_origin), whitespace_grammar< Iterator > > cholesky_factor_decl_r
boost::spirit::qi::rule< Iterator, expression(var_origin), whitespace_grammar< Iterator > > int_data_expr_r
AST structure for a range object with a low and high value.
Definition: range.hpp:14
boost::spirit::qi::rule< Iterator, expression(var_origin), whitespace_grammar< Iterator > > def_r
boost::spirit::qi::rule< Iterator, expression(var_origin), whitespace_grammar< Iterator > > dim1_r
boost::spirit::qi::rule< Iterator, range(var_origin), whitespace_grammar< Iterator > > range_brackets_int_r
boost::spirit::qi::rule< Iterator, simplex_var_decl(var_origin), whitespace_grammar< Iterator > > simplex_decl_r
Structure to hold the declaration of a unit vector.
boost::spirit::qi::rule< Iterator, int_var_decl(var_origin), whitespace_grammar< Iterator > > int_decl_r
int var_origin
The type of a variable indicating where a variable was declared.
Definition: var_origin.hpp:12
Structure to hold a matrix variable declaration.
Structure to hold a Cholesky factor variable declaration.
boost::spirit::qi::rule< Iterator, double_var_decl(var_origin), whitespace_grammar< Iterator > > double_decl_r
Structure to hold a column vector variable declaration.
expression07_grammar< Iterator > expression07_g
The variant structure to hold a variable declaration.
Definition: var_decl.hpp:30
boost::spirit::qi::rule< Iterator, std::vector< expression >var_origin), whitespace_grammar< Iterator > > dims_r
Structure to hold a correlation matrix variable declaration.
boost::spirit::qi::rule< Iterator, expression(var_origin), whitespace_grammar< Iterator > > opt_def_r
boost::spirit::qi::rule< Iterator, boost::spirit::qi::locals< bool >, var_decl(bool, var_origin), whitespace_grammar< Iterator > > var_decl_r
boost::spirit::qi::rule< Iterator, range(var_origin), whitespace_grammar< Iterator > > range_brackets_double_r
boost::spirit::qi::rule< Iterator, vector_var_decl(var_origin), whitespace_grammar< Iterator > > vector_decl_r
An integer variable declaration and optional definition.
boost::spirit::qi::rule< Iterator, cov_matrix_var_decl(var_origin), whitespace_grammar< Iterator > > cov_matrix_decl_r
Structure to hold the declaration of an ordered vector.
var_decls_grammar(variable_map &var_map, std::stringstream &error_msgs)
boost::spirit::qi::rule< Iterator, corr_matrix_var_decl(var_origin), whitespace_grammar< Iterator > > corr_matrix_decl_r
boost::spirit::qi::rule< Iterator, boost::spirit::qi::locals< bool >, std::vector< var_decl >bool, var_origin), whitespace_grammar< Iterator > > var_decls_r
boost::spirit::qi::rule< Iterator, std::vector< expression >var_origin), whitespace_grammar< Iterator > > opt_dims_r

     [ Stan Home Page ] © 2011–2016, Stan Development Team.