:relfileprefix: ../../../
[#boost-urls-grammar-unsigned_rule]

== xref:boost.adoc[pass:[boost]]::xref:boost/urls.adoc[pass:[urls]]::xref:boost/urls/grammar.adoc[pass:[grammar]]::unsigned_rule


Match an unsigned decimal


=== Synopsis

Declared in header `<https://www.github.com/boostorg/url/blob/develop/include/boost/url/grammar/unsigned_rule.hpp#L83[boost/url/grammar/unsigned_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Unsigned>
struct unsigned_rule;
----

===  Types
[cols=2,separator=¦]
|===
¦Name ¦Description
¦xref:boost/urls/grammar/unsigned_rule/value_type.adoc[`value_type`]  ¦

|===
===  Member Functions
[cols=2,separator=¦]
|===
¦Name ¦Description
¦xref:boost/urls/grammar/unsigned_rule/parse.adoc[`parse`]  ¦

|===

=== Description


Extra leading zeroes are disallowed.
[,cpp]
----
using value_type = Unsigned;
----

=== Rules are used with the function

xref:boost/urls/grammar/unsigned_rule/parse.adoc[parse]
.
[,cpp]
----
system::result< unsigned short > rv = parse( "32767", unsigned_rule< unsigned short >{} );
----
[,cpp]
----
unsigned      = "0" / ( ["1"..."9"] *DIGIT )
----



=== See Also


xref:boost/urls/grammar/parse-02.adoc[grammar::parse]
.



