#include <parser.h>
Public Member Functions | |
parser (lexer::pointer_t l) | |
node::pointer_t | component_value () |
node::pointer_t | component_value_list () |
node::pointer_t | declaration_list () |
node::pointer_t | rule () |
node::pointer_t | rule_list () |
node::pointer_t | stylesheet () |
Static Public Member Functions | |
static bool | argify (node::pointer_t n, node_type_t const separator=node_type_t::COMMA) |
static bool | is_nested_declaration (node::pointer_t n) |
static bool | is_variable_set (node::pointer_t n, bool with_block) |
Private Member Functions | |
node::pointer_t | at_rule (node::pointer_t at_keyword) |
node::pointer_t | block (node::pointer_t b, node_type_t closing_token) |
node::pointer_t | block_list (node::pointer_t b) |
node::pointer_t | component_value (node::pointer_t n) |
node::pointer_t | component_value_list (node::pointer_t n, int flags) |
node::pointer_t | declaration (node::pointer_t identifier) |
node::pointer_t | declaration_list (node::pointer_t n) |
node::pointer_t | next_token () |
node::pointer_t | qualified_rule (node::pointer_t n) |
node::pointer_t | rule (node::pointer_t n) |
node::pointer_t | rule_list (node::pointer_t n) |
node::pointer_t | stylesheet (node::pointer_t n) |
Private Attributes | |
node::pointer_t | f_last_token = node::pointer_t() |
lexer::pointer_t | f_lexer = lexer::pointer_t() |
csspp::parser::parser | ( | lexer::pointer_t | l | ) |
Definition at line 63 of file parser.cpp.
References next_token().
|
static |
Definition at line 789 of file parser.cpp.
References csspp::ARG, csspp::COMMA, csspp::DIVIDE, csspp::ERROR_ERROR, csspp::error::instance(), csspp::LIST, csspp::OPEN_CURLYBRACKET, csspp::error::reset(), and csspp::WHITESPACE.
Referenced by csspp::compiler::compile_at_keyword(), csspp::compiler::compile_declaration(), csspp::compiler::parse_selector(), csspp::compiler::prepare_function_arguments(), csspp::compiler::replace_variable(), and csspp::expression::unary().
|
private |
Definition at line 207 of file parser.cpp.
References component_value_list(), csspp::ERROR_ERROR, f_last_token, csspp::error::instance(), next_token(), csspp::OPEN_CURLYBRACKET, and csspp::SEMICOLON.
Referenced by component_value_list(), declaration_list(), rule(), and stylesheet().
|
private |
Definition at line 590 of file parser.cpp.
References component_value_list(), csspp::ERROR_ERROR, f_last_token, csspp::error::instance(), next_token(), and csspp::WHITESPACE.
Referenced by component_value().
|
private |
Definition at line 617 of file parser.cpp.
References csspp::CDC, csspp::CDO, csspp::CLOSE_CURLYBRACKET, csspp::CLOSE_PARENTHESIS, csspp::CLOSE_SQUAREBRACKET, component_value_list(), csspp::EOF_TOKEN, csspp::ERROR_ERROR, f_last_token, csspp::error::instance(), next_token(), and csspp::WHITESPACE.
Referenced by component_value().
node::pointer_t csspp::parser::component_value | ( | ) |
Definition at line 94 of file parser.cpp.
References component_value(), and f_last_token.
Referenced by component_value(), and component_value_list().
|
private |
Definition at line 562 of file parser.cpp.
References block(), block_list(), csspp::CLOSE_PARENTHESIS, csspp::CLOSE_SQUAREBRACKET, csspp::FUNCTION, next_token(), csspp::OPEN_CURLYBRACKET, csspp::OPEN_PARENTHESIS, csspp::OPEN_SQUAREBRACKET, and csspp::VARIABLE_FUNCTION.
node::pointer_t csspp::parser::component_value_list | ( | ) |
Definition at line 89 of file parser.cpp.
References component_value_list(), and f_last_token.
Referenced by at_rule(), block(), block_list(), component_value_list(), declaration(), and qualified_rule().
|
private |
Definition at line 369 of file parser.cpp.
References csspp::AT_KEYWORD, at_rule(), csspp::CDC, csspp::CDO, csspp::CLOSE_CURLYBRACKET, csspp::CLOSE_PARENTHESIS, csspp::CLOSE_SQUAREBRACKET, csspp::COMPONENT_VALUE, component_value(), csspp::EOF_TOKEN, csspp::ERROR_ERROR, csspp::EXCLAMATION, f_last_token, csspp::IDENTIFIER, csspp::error::instance(), is_nested_declaration(), is_variable_set(), csspp::LIST, next_token(), csspp::OPEN_CURLYBRACKET, csspp::OPEN_PARENTHESIS, csspp::OPEN_SQUAREBRACKET, csspp::SEMICOLON, and csspp::WHITESPACE.
|
private |
Definition at line 335 of file parser.cpp.
References csspp::COLON, component_value_list(), csspp::DECLARATION, csspp::ERROR_ERROR, csspp::error::instance(), next_token(), and csspp::WHITESPACE.
Referenced by declaration_list().
node::pointer_t csspp::parser::declaration_list | ( | ) |
Definition at line 84 of file parser.cpp.
References declaration_list(), and f_last_token.
Referenced by declaration_list().
|
private |
Definition at line 285 of file parser.cpp.
References csspp::AT_KEYWORD, at_rule(), declaration(), csspp::EOF_TOKEN, csspp::ERROR_ERROR, f_last_token, csspp::IDENTIFIER, csspp::error::instance(), csspp::LIST, next_token(), csspp::SEMICOLON, and csspp::WHITESPACE.
|
static |
Definition at line 703 of file parser.cpp.
References csspp::ADD, csspp::COLON, csspp::COMMA, csspp::FUNCTION, csspp::GREATER_THAN, csspp::HASH, csspp::IDENTIFIER, csspp::MULTIPLY, csspp::OPEN_CURLYBRACKET, csspp::OPEN_SQUAREBRACKET, csspp::PERIOD, csspp::PLACEHOLDER, csspp::PRECEDED, csspp::REFERENCE, csspp::SCOPE, and csspp::WHITESPACE.
Referenced by csspp::compiler::compile_component_value(), and component_value_list().
|
static |
Definition at line 667 of file parser.cpp.
References csspp::COLON, csspp::OPEN_CURLYBRACKET, csspp::VARIABLE, csspp::VARIABLE_FUNCTION, and csspp::WHITESPACE.
Referenced by csspp::compiler::compile_component_value(), component_value_list(), csspp::compiler::mark_selectors(), qualified_rule(), and csspp::compiler::replace_variables().
|
private |
Definition at line 99 of file parser.cpp.
References f_last_token, and f_lexer.
Referenced by parser(), at_rule(), block(), block_list(), component_value(), component_value_list(), declaration(), declaration_list(), qualified_rule(), rule(), and stylesheet().
|
private |
Definition at line 239 of file parser.cpp.
References component_value_list(), csspp::EOF_TOKEN, csspp::ERROR_ERROR, csspp::error::instance(), is_variable_set(), next_token(), csspp::OPEN_CURLYBRACKET, and csspp::SEMICOLON.
Referenced by rule(), and stylesheet().
node::pointer_t csspp::parser::rule | ( | ) |
Definition at line 79 of file parser.cpp.
References f_last_token, and rule().
Referenced by rule(), and rule_list().
|
private |
Definition at line 171 of file parser.cpp.
References csspp::AT_KEYWORD, at_rule(), csspp::CDC, csspp::CDO, csspp::CLOSE_CURLYBRACKET, csspp::CLOSE_PARENTHESIS, csspp::CLOSE_SQUAREBRACKET, csspp::EOF_TOKEN, csspp::ERROR_ERROR, csspp::error::instance(), next_token(), qualified_rule(), and csspp::WHITESPACE.
node::pointer_t csspp::parser::rule_list | ( | ) |
Definition at line 74 of file parser.cpp.
References f_last_token, and rule_list().
Referenced by rule_list().
|
private |
Definition at line 158 of file parser.cpp.
References csspp::EOF_TOKEN, f_last_token, csspp::LIST, and rule().
node::pointer_t csspp::parser::stylesheet | ( | ) |
Definition at line 69 of file parser.cpp.
References f_last_token, and stylesheet().
Referenced by anonymous_namespace{csspp.cpp}::pp::compile(), csspp::compiler::replace_import(), csspp::compiler::set_validation_script(), and stylesheet().
|
private |
Definition at line 106 of file parser.cpp.
References csspp::AT_KEYWORD, at_rule(), csspp::CDC, csspp::CDO, csspp::CLOSE_CURLYBRACKET, csspp::CLOSE_PARENTHESIS, csspp::CLOSE_SQUAREBRACKET, csspp::COMMENT, csspp::EOF_TOKEN, csspp::ERROR_ERROR, f_last_token, csspp::error::instance(), csspp::LIST, next_token(), qualified_rule(), and csspp::WHITESPACE.
|
private |
Definition at line 58 of file parser.h.
Referenced by at_rule(), block(), block_list(), component_value(), component_value_list(), component_value_list(), declaration_list(), declaration_list(), next_token(), rule(), rule_list(), rule_list(), stylesheet(), and stylesheet().
|
private |
Definition at line 57 of file parser.h.
Referenced by next_token().
Documentation of CSS Preprocessor.
This document is part of the Snap! Websites Project.
Copyright by Made to Order Software Corp.