Lexer->addSpecialPattern( '(?<=\b)(?:[1-9]|\d{2,})[xX]\d+(?=\b)', $mode, 'multiplyentity' ); } /** @inheritdoc */ public function handle($match, $state, $pos, Handler $handler) { preg_match_all('/\d+/', $match, $matches); $handler->addCall('multiplyentity', [$matches[0][0], $matches[0][1]], $pos); return true; } }