I tried to use qi::uint_parser<int>()
. But it is the same like qi::uint_
. They all match integers range from 0
to std::numeric_limits<unsigned int>::max()
.
Is qi::uint_parser<int>()
designed to be like this? What parser shall I use to match an integer range from 0
to std::numeric_limits<int>::max()
? Thanks.
Simplest demo, attaching a semantic action to do the range check:
Live On Coliru
Prints