lib/lexer.js
function(regex) {
    var m = regex.exec(this.input);
    if (m) {
      this.updatePosition(m[0], m[0].length);
      return m;
    }
  }
function(regex) {
    var m = regex.exec(this.input);
    if (m) {
      this.updatePosition(m[0], m[0].length);
      return m;
    }
  }
function ( regex ) { var m = regex . exec ( this . input ) ; if ( m ) { this . updatePosition ( m [ 0 ] , m [ 0 ] . length ) ; return m ; } }
Match `regex`, return captures, and update the cursor position by `match[0]` length.
@param {RegExp} `regex`
@return {Object}
Match regex return captures and update the cursor position by match [ 0 ] length .