protected function patternSymbolsSplit(array $symbols, $separator, $optional_right_fragment = FALSE) {
    $separator_position = NULL;
    foreach ($symbols as $position => $symbol) {
      if (!($symbol instanceof NumberPatternSymbol)) {
        throw new \InvalidArgumentException();
      }
      if ($symbol->symbol === $separator && !$symbol->escaped) {
        if (is_null($separator_position)) {
          $separator_position = $position;
        }
        else {
          throw new \RunTimeException("Illegal separator ($separator) at position $symbol->position.");
        }
      }
    }

    if (!$separator_position) {
      if ($optional_right_fragment) {
        return array($symbols, FALSE);
      }
      throw new \RunTimeException("Missing separator ($separator).");
    }
    else {
      return array(
        array_slice($symbols, 0, $separator_position),
        array_slice($symbols, $separator_position + 1),
      );
    }
  }