original_string: public function addBlockType($type, $tag, $continuable = false, $completable = false, $index = null)
      {
          $block = &$this->unmarkedBlockTypes;
          if ($type) {
              if (!isset($this->BlockTypes[$type])) {
                  $this->BlockTypes[$type] = [];
              }
              $block = &$this->BlockTypes[$type];
          }
  
          if (null === $index) {
              $block[] = $tag;
          } else {
              array_splice($block, $index, 0, [$tag]);
          }
  
          if ($continuable) {
              $this->continuable_blocks[] = $tag;
          }
          if ($completable) {
              $this->completable_blocks[] = $tag;
          }
      }
code: public function addBlockType($type, $tag, $continuable = false, $completable = false, $index = null)
      {
          $block = &$this->unmarkedBlockTypes;
          if ($type) {
              if (!isset($this->BlockTypes[$type])) {
                  $this->BlockTypes[$type] = [];
              }
              $block = &$this->BlockTypes[$type];
          }
  
          if (null === $index) {
              $block[] = $tag;
          } else {
              array_splice($block, $index, 0, [$tag]);
          }
  
          if ($continuable) {
              $this->continuable_blocks[] = $tag;
          }
          if ($completable) {
              $this->completable_blocks[] = $tag;
          }
      }
code_tokens: public function addBlockType ( $ type , $ tag , $ continuable = false , $ completable = false , $ index = null ) { $ block = & $ this -> unmarkedBlockTypes ; if ( $ type ) { if ( ! isset ( $ this -> BlockTypes [ $ type ] ) ) { $ this -> BlockTypes [ $ type ] = [ ] ; } $ block = & $ this -> BlockTypes [ $ type ] ; } if ( null === $ index ) { $ block [ ] = $ tag ; } else { array_splice ( $ block , $ index , 0 , [ $ tag ] ) ; } if ( $ continuable ) { $ this -> continuable_blocks [ ] = $ tag ; } if ( $ completable ) { $ this -> completable_blocks [ ] = $ tag ; } }
docstring: Be able to define a new Block type or override an existing one
  
  @param string $type
  @param string $tag
  @param bool $continuable
  @param bool $completable
  @param int|null $index
docstring_tokens: Be able to define a new Block type or override an existing one