title: How extract unsigned value from matched string?
body: <p>I need to write lexical analyzer with ability to parse tokens like x(t-1), u(t), u(t-4), a0, a1,... and attributes of this lexemes should be "unsigned" (as example attribute value for token x(t-2) should be 2). I can define all this tokens via regular expressions, but i don't know how i can extract attribute value from matched string.</p>
  
  <p>P.S. This lexer will be used in boost spirit qi grammar.</p>
  
  <p>So, does anybody know way how i can do this?</p>