original_string: protected function deep_clone($value) {
          if (is_object($value)) {
              // Objects must be cloned to begin with.
              $value = clone $value;
          }
          if (is_array($value) || is_object($value)) {
              foreach ($value as $key => $subvalue) {
                  $value[$key] = $this->deep_clone($subvalue);
              }
          }
          return $value;
      }
code: protected function deep_clone($value) {
          if (is_object($value)) {
              // Objects must be cloned to begin with.
              $value = clone $value;
          }
          if (is_array($value) || is_object($value)) {
              foreach ($value as $key => $subvalue) {
                  $value[$key] = $this->deep_clone($subvalue);
              }
          }
          return $value;
      }
code_tokens: protected function deep_clone ( $ value ) { if ( is_object ( $ value ) ) { // Objects must be cloned to begin with. $ value = clone $ value ; } if ( is_array ( $ value ) || is_object ( $ value ) ) { foreach ( $ value as $ key => $ subvalue ) { $ value [ $ key ] = $ this -> deep_clone ( $ subvalue ) ; } } return $ value ; }
docstring: Creates a reference free clone of the given value.
  
  @param mixed $value
  @return mixed
docstring_tokens: Creates a reference free clone of the given value .