Match a non‐empty string of characters from a set
Synopsis
template<CharSet CS>
constexpr
/* implementation-defined */
token_rule(CS const& cs) noexcept;
Description
If there is no more input, the error code error::need_more
is returned.
Value Type
using value_type = core::string_view;
Example
Rules are used with the function parse
.
system::result< core::string_view > rv = parse( "abcdef", token_rule( alpha_chars ) );
BNF
token = 1*( ch )
Return Value
The token rule
Parameters
Name |
Description |
cs |
The character set to use |
See Also
alpha_chars
, parse
.
Created with MrDocs