original_string: public static function flatten(array $arr)
      {
          $flat = [];
          foreach ($arr as $v) {
              if (is_array($v)) {
                  $flat = array_merge($flat, self::flatten($v));
              } else {
                  $flat[] = $v;
              }
          }
          return $flat;
      }
code: public static function flatten(array $arr)
      {
          $flat = [];
          foreach ($arr as $v) {
              if (is_array($v)) {
                  $flat = array_merge($flat, self::flatten($v));
              } else {
                  $flat[] = $v;
              }
          }
          return $flat;
      }
code_tokens: public static function flatten ( array $ arr ) { $ flat = [ ] ; foreach ( $ arr as $ v ) { if ( is_array ( $ v ) ) { $ flat = array_merge ( $ flat , self :: flatten ( $ v ) ) ; } else { $ flat [ ] = $ v ; } } return $ flat ; }
docstring: Flattens an array.
docstring_tokens: Flattens an array .