original_string: protected function addToComponentTreeSubset(array &$pointer, $componentId)
      {
          foreach ($this->graphComponents[$componentId]['path'] as $node) {
              if (empty($pointer[$node])) {
                  $pointer[$node] = [];
              }
              $pointer =& $pointer[$node];
          }
          $pointer[] = $componentId;
  
          if ($this->graphComponents[$componentId]['master']) {
              $dependencies = array_column($this->graphComponents[$componentId]['master']['dependencies'], 'class');
              foreach ($this->graphComponents[$componentId]['master']['variants'] as $variant) {
                  $dependencies = array_column($variant['dependencies'], 'class');
              }
          } else {
              $dependencies = array_column($this->graphComponents[$componentId]['dependencies'], 'class');
          }
  
          return array_unique($dependencies);
      }
code: protected function addToComponentTreeSubset(array &$pointer, $componentId)
      {
          foreach ($this->graphComponents[$componentId]['path'] as $node) {
              if (empty($pointer[$node])) {
                  $pointer[$node] = [];
              }
              $pointer =& $pointer[$node];
          }
          $pointer[] = $componentId;
  
          if ($this->graphComponents[$componentId]['master']) {
              $dependencies = array_column($this->graphComponents[$componentId]['master']['dependencies'], 'class');
              foreach ($this->graphComponents[$componentId]['master']['variants'] as $variant) {
                  $dependencies = array_column($variant['dependencies'], 'class');
              }
          } else {
              $dependencies = array_column($this->graphComponents[$componentId]['dependencies'], 'class');
          }
  
          return array_unique($dependencies);
      }
code_tokens: protected function addToComponentTreeSubset ( array & $ pointer , $ componentId ) { foreach ( $ this -> graphComponents [ $ componentId ] [ 'path' ] as $ node ) { if ( empty ( $ pointer [ $ node ] ) ) { $ pointer [ $ node ] = [ ] ; } $ pointer = & $ pointer [ $ node ] ; } $ pointer [ ] = $ componentId ; if ( $ this -> graphComponents [ $ componentId ] [ 'master' ] ) { $ dependencies = array_column ( $ this -> graphComponents [ $ componentId ] [ 'master' ] [ 'dependencies' ] , 'class' ) ; foreach ( $ this -> graphComponents [ $ componentId ] [ 'master' ] [ 'variants' ] as $ variant ) { $ dependencies = array_column ( $ variant [ 'dependencies' ] , 'class' ) ; } } else { $ dependencies = array_column ( $ this -> graphComponents [ $ componentId ] [ 'dependencies' ] , 'class' ) ; } return array_unique ( $ dependencies ) ; }
docstring: Recursively add a single component to a component tree subset
  
  @param array $pointer      Component tree subset
  @param string $componentId Component class
  
  @return array Component dependencies
docstring_tokens: Recursively add a single component to a component tree subset