Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for a snapshot of the master branch, built from commit 5002c2d6a2.
PrevUpHomeNext

grammar::unsigned_rule

Match an unsigned decimal.

Synopsis

Defined in header <boost/url/grammar/unsigned_rule.hpp>

template<
    class Unsigned>
struct unsigned_rule
Description

Extra leading zeroes are disallowed.

Value Type
using value_type = Unsigned;
Example

Rules are used with the function parse.

result< unsigned short > rv = parse( "32767", unsigned_rule< unsigned short >{} );
BNF
unsigned      = "0" / ( ["1"..."9"] *DIGIT )
Template Parameters

Type

Description

Unsigned

The unsigned integer type used to store the result.

See Also

grammar::parse.

Convenience header <boost/url/grammar.hpp>


PrevUpHomeNext