Classes | Namespaces | Macros | Typedefs | Enumerations | Functions | Variables
grammar.hpp File Reference
#include <cstdint>
#include <lexy/_detail/config.hpp>
#include <lexy/_detail/detect.hpp>
#include <lexy/_detail/type_name.hpp>
#include <lexy/callback/base.hpp>
Include dependency graph for grammar.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  lexyd::_char_class_base
 
struct  lexyd::_lit_base
 
struct  lexyd::_lset_base
 
struct  lexyd::_operation_base
 
struct  lexyd::_sep_base
 
struct  lexy::_sfinae_sink< Production, Sink >
 
struct  lexyd::_token_base
 
struct  lexyd::branch_base
 
struct  lexy::production_info
 
class  lexy::production_value_callback< Production, ParseState >
 
struct  lexyd::rule_base
 
struct  lexy::token_production
 
struct  lexy::transparent_production
 
struct  lexyd::unconditional_branch_base
 

Namespaces

 lexy
 
 lexyd
 

Macros

#define LEXY_REQUIRE_BRANCH_RULE(Rule, Name)
 

Typedefs

template<typename Production >
using lexy::_detect_max_recursion_depth = decltype(Production::max_recursion_depth)
 
template<typename Production >
using lexy::_detect_value = decltype(Production::value)
 
template<typename ParseState , typename Production >
using lexy::_detect_value_of = typename decltype(LEXY_DECLVAL(ParseState &).value_of(Production{}))::return_type
 
template<typename Production >
using lexy::_detect_whitespace = decltype(Production::whitespace)
 
template<typename T >
using lexy::_enable_production_or_operation = std::enable_if_t< is_production< T >||is_operation< T > >
 
template<typename Production >
using lexy::production_rule = LEXY_DECAY_DECLTYPE(Production::rule)
 
template<typename Production , typename WhitespaceProduction >
using lexy::production_whitespace = decltype(_production_whitespace< Production, WhitespaceProduction >())
 

Enumerations

enum  lexy::predefined_token_kind : std::uint_least16_t {
  lexy::unknown_token_kind = UINT_LEAST16_MAX, lexy::error_token_kind = UINT_LEAST16_MAX - 1, lexy::whitespace_token_kind = UINT_LEAST16_MAX - 2, lexy::any_token_kind = UINT_LEAST16_MAX - 3,
  lexy::literal_token_kind = UINT_LEAST16_MAX - 4, lexy::position_token_kind = UINT_LEAST16_MAX - 5, lexy::eof_token_kind = UINT_LEAST16_MAX - 6, lexy::identifier_token_kind = UINT_LEAST16_MAX - 7,
  lexy::digits_token_kind = UINT_LEAST16_MAX - 8, lexy::_smallest_predefined_token_kind = digits_token_kind
}
 

Functions

template<typename Production , typename WhitespaceProduction >
auto lexy::_production_whitespace ()
 
template<typename EntryProduction >
LEXY_CONSTEVAL std::size_t lexy::max_recursion_depth ()
 
template<typename Production >
const LEXY_CONSTEVAL char * lexy::production_name ()
 
template<typename T >
constexpr const char * lexy::token_kind_name (const T &) noexcept
 
constexpr const char * lexy::token_kind_name (predefined_token_kind kind) noexcept
 

Variables

template<typename To , typename... Args>
constexpr auto lexy::_is_convertible = false
 
template<typename To , typename Arg >
constexpr auto lexy::_is_convertible< To, Arg > = std::is_convertible_v<Arg, To>
 
template<>
constexpr auto lexy::_is_convertible< void > = true
 
template<typename Production >
constexpr auto lexy::_production_defines_whitespace = lexy::_detail::is_detected<_detect_whitespace, Production>
 
template<typename... T>
constexpr bool lexy::_require_branch_rule = (is_branch_rule<T> && ...)
 
template<typename T >
constexpr bool lexy::is_branch_rule = std::is_base_of_v<dsl::branch_base, T>
 
template<typename T >
constexpr bool lexy::is_char_class_rule = std::is_base_of_v<dsl::_char_class_base, T>
 
template<typename T >
constexpr bool lexy::is_literal_rule = std::is_base_of_v<dsl::_lit_base, T>
 
template<typename T >
constexpr bool lexy::is_literal_set_rule = std::is_base_of_v<dsl::_lset_base, T>
 
template<typename T >
constexpr auto lexy::is_operation = std::is_base_of_v<lexy::dsl::_operation_base, T>
 
template<typename Production >
constexpr bool lexy::is_production = _detail::is_detected<production_rule, Production>
 
template<typename T >
constexpr bool lexy::is_rule = std::is_base_of_v<dsl::rule_base, T>
 
template<typename T >
constexpr auto lexy::is_separator = std::is_base_of_v<lexy::dsl::_sep_base, T>
 
template<typename Production >
constexpr bool lexy::is_token_production = std::is_base_of_v<token_production, Production>
 
template<typename T >
constexpr bool lexy::is_token_rule = std::is_base_of_v<dsl::_token_base, T>
 
template<typename Production >
constexpr bool lexy::is_transparent_production = std::is_base_of_v<transparent_production, Production>
 
template<typename T >
constexpr bool lexy::is_unconditional_branch_rule = std::is_base_of_v<dsl::unconditional_branch_base, T>
 
template<typename Production , typename ParseState = void>
constexpr bool lexy::production_has_value_callback
 
template<typename TokenRule >
constexpr auto lexy::token_kind_of = lexy::unknown_token_kind
 Specialize to define the token kind of a rule. More...
 
template<typename TokenRule >
constexpr auto lexy::token_kind_of< const TokenRule > = token_kind_of<TokenRule>
 

Macro Definition Documentation

◆ LEXY_REQUIRE_BRANCH_RULE

#define LEXY_REQUIRE_BRANCH_RULE (   Rule,
  Name 
)
Value:
static_assert(lexy::_require_branch_rule<Rule>, Name \
" requires a branch condition." \
" You may need to use `>>` to specify the condition that is used for dispatch." \
" See https://lexy.foonathan.net/learn/branching/ for more information.")

Definition at line 73 of file grammar.hpp.



behaviortree_cpp_v4
Author(s): Davide Faconti
autogenerated on Fri Dec 13 2024 03:19:18